473,385 Members | 1,798 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Passing input values between pages.

11
I'm sure this should be simple enough but I'm really struggling to get my mind around this. I don't have access to a server but am developing a site and I need to pass information from input boxes on one form to a paragraph of text on another.

The simplest example I could think of would be a first page with input boxes for Title and Surname:
[html]
<head>

<title>Test</title>

<table>

<tr>
<td>Title:</td>
<td><p>
<input name="Title" type="text" id="Title" size="20" maxlength="4">
</p> </td>
</tr>
<tr>

<td>Surname:</td>
<td><input name="Surname" type="Text" id="Surname" size="35" maxlength="50"></td>
</tr>


<td><input name="Reset" type="Reset"
value="Clear Form" />
<a href="Test_Page2.html">Next</a>
</body>
</html>
[/html]

and a second page which would then show the values in text.

[html]
<head>

<title>Untitled Document</title>
</head>

<body>
Hello
</body>

</html>
[/html]
So if I open the first page and put in Mr and Smith the second page reads "Hello Mr Smith"

I've read some information about querystrings and passing information through the link and retrieving it in the next page but can someone help to explain it in this example so I can see it working.

Thanks.
Sep 1 '07 #1
6 2380
Death Slaught
1,137 1GB
You could just use Javascript in my opinion it would be easier heres a link to it just find the javascript tutorial on the left.

Thanks, Death
Sep 1 '07 #2
Death Slaught
1,137 1GB
O and please use proper HTML tags you can find them above the textbox the HTML one looks like this <>

- Death
Sep 1 '07 #3
DLP35
11
Thanks, Not sure what happened to the tags, pasted out and back into Dreamweaver fine.

Any other thoughts out there?
Sep 1 '07 #4
drhowarddrfine
7,435 Expert 4TB
As stated, if the form is on the same page then you must use javascript, or submit the form to a server where the language there can handle it and reserve the page.
Sep 1 '07 #5
DLP35
11
OK & thanks for updating the text.

The input side is on a different page to the output side but within the same browser session and it won't be interacting with a server.

What would the javascipt be on the two pages in the example above?

It might seem that I'm being stupid, but I'm not going to "get it" from reading another set of online tutorials (we do all have different learning styles after all)
- but I'm convinced if i can just see it working in a simple example like this I can apply the principles in my design.

Thanks again.
Sep 2 '07 #6
drhowarddrfine
7,435 Expert 4TB
You need to ask that question on the javascript board.
Sep 2 '07 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Paul | last post by:
I want to use sessions to cover myself in case the user switches off cookies so I am passing the session ID manually through a hidden input field. This is what I have so far. index.php page...
1
by: Paul | last post by:
Hmmm, didn't seem to work. I have set session.use_cookies = 1 and session.use_trans_sid = 1 in my php.ini file. Index.php contains:...
5
by: Raju V.K | last post by:
I am developing a web site which requires a set og unique values be transferred between pages and server many times. There fore i decided to put the values in an array so that only one reference to...
10
by: Joseph S. | last post by:
Hi, How do I pass a string from one call to a php block to another call in the same page but from another form? Here's my full php code: I'm using two forms in the same page. A hidden field...
1
by: olduncleamos | last post by:
Hello all. With a background in ASP, I am finding the work required for passing values between pages mystifying. For various obvious reasons, I have eliminated using cookies and session to store...
1
by: williamroy | last post by:
Hello, I've got a form that runs over 5 pages. I need the last page submit button to post all of the answers at one time from the previous 5 pages (to another server). I'd like to see the last...
28
by: Skeets | last post by:
i'm passing session and hidden variables between pages. not to mention post values. i'm a little concerned that someone with sufficient knowledge could spoof these vlaues and manipulate the...
4
by: Auddog | last post by:
I'm needing to work with a bar code scanner and have come to realize that after scanning a barcode the unit actually does a hard return. What is the best way to variables from one page to another....
1
by: Steve | last post by:
After a few hours of trial and error I have reached the following conclusions, can you please tell me if I am right: I have 2 aspx pages both with the same master page and I wish to pass values...
15
by: DLP35 | last post by:
I've been referred here from the HTML forum as I'm told the answer lies in javascript. I'm sure this should be simple enough but I'm really struggling to get my mind around this. I don't have...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.