Passing Value To Different Page
i have a page home.php which has a dropdown menu for the user to select an institution and a Go button. once the user selects an option, a new page named institution.php will be opened which will display information about the institution which was selected previously.
i do not want to have different pages for each institution, so that's why i have one page to display the information according to the option selected in home.php. the problem is, when the user selects an option and click Go, the institution.php doesn't show any data from the db about the institution selected, not even the images that i have. can anyone tell me what's wrong? Code:
View Complete Forum Thread with Replies
Related Forum Messages:
Passing A Parameter From An HTML Page To A PHP Page
I want to pass a language value (EN/FR/DE etc.) from an Index HTML page to a PHP page with a language code in the call, so that the PHP page can select texts in that language. I would like to to it from an unordered list item if possible by extending the link ... <li><a href="scripts/pricelist.php???>Pricelist[/url]</li>
View Replies !
Passing Variables From A Page To An ASP Page?
I have a site using a PHP CMS and I need it to use an ASP module from another site but I would like to use a frame so it looks like it is still in the same site. I need to pass a username variable from a form in in the PHP webspace (where the domain is pointing) to a page in an ASP webspace (using a subdomain not related to the main domain). I created a frame page in the php hosting with a 1px top frame and the main frame pointing to the asp page but of course the variable is not being passed.....if I put the ASP connection code on the frameset page it doesn't recognize it because the hosting is a Unix/PHP hosting only. My question to you is: Can a variable be passed from the php to the ASP webspace using some other technique? I just need to have the ASP module showing as if it is in the PHP.
View Replies !
[HELP PLEASE] Passing Variable To New Page
I am having hard time passing the variable to the next page. May be you can help me. Let me explain: I am using mySQL database to store information about images (ID, name, author, description, etc). I am pulling some of the information to create this (look at the example here: http://www.gibsonusa.com/test/page/index.php) Now, I want a new window appear when user clicks on the image. I have achieved it with the following script: echo "<script language="JavaScript">"; echo" function pop1() {"; echo" window.open("info.php?prod_id=$result[0]"); }"; $result[0] is variable that stores id of the image in database echo "</script>"; I am calling this function in the following manner: echo"<img onclick="pop1();""; You can see the result if you click on the image. The new page opens up, BUT the id (product_id in this case) value is not passed to the next page correctly. If you click on the first or second image on the first page it shows that the ID is the same for both of them. However if you look at the source code you can see that the ids are assigned correctly. The same thing happens if you click on any image that says “no image available” (I am using different script to generate those). It seems that the script picks up and stores in the memory the value of an ID of the last image generated with the script (I don’t know if that make sense). Oh, by the way the contents of info.php that I am calling in the script above are as following: <? $myid = $_GET['prod_id']; echo" Product ID: $myid<br>"; ?> What am I doing wrong? Can you help? Thank you.
View Replies !
Passing An Image From One Page To The Next.
I want the user to input information, submit it and be able to check it before having it go to the database.This information will include an image.How do I pass the image from the input page to the next page before having it go to the database?
View Replies !
Passing A Variable To A Page
Is it possible to pass a varialble to a page using just PHP/HTML. The object is to create a agenda page, with information comming from MySql, based on the choise of month in the index page in a different frame, i.e. the month is selected in frame 1. Now i want to sent the choice of the user to a page, to be shown in frame 2, that is created with PHP, and use the variable in the MySql query.I know this can be done using java, but i would like to avoid that.
View Replies !
Passing Result To New Page.
I have a search result with a link which links to the ID# of the record. By clicking on the link I would like the rest of the record displayed. What will my script look like to pull a particular record ID?
View Replies !
Passing Strings To Another Page
when this code sends the category to the next page it only sends part of the information.. ex… if the selection consist of 1 word its fine but if it consists of 2 words it only sends the first word >>>”network card” sends the word “network” and not “network card” and if its “monitor” and since its 1 word its fine.. What am I doing wrong.. I’m kind of new to php and if you could let me know it would be greatly appreciated. I think my confusing is with the format of this line perhaps where the quotes and slashes go, not sure. Other wise this code does work. I can see it in the address field that it separates the selection but need to send the whole thing as 1 word. <php echo "<a href="displaylist.php?cmd=".$row["CATEGORY"]."">". $row["CATEGORY"]." (".$row["ENTRIES"].")</A>"; ?>
View Replies !
Passing Big Arrays To Another Page
I'm having a little problem on my advanced search system with large amounts of results, when trying to pass them to another page. Tried to use the serialize function but when the results reach a number, for instance, of 300 the link will not handle that. It works for small resultsets. When user search the database for (example) stores in "New York" we get 256 results. Now I want to give the user the chance to search on these results, the stores found in the former query that sell "bread", which would take the user to another page called "advanced search for store features". This to avoid the use of big forms for these advanced searches, where I've created a degree set of search pages (I have about an overall 250 features to search). The main problem seems to pass the array to the other page when large ammounts of data are set on this array, which I'll call here as $storeIDs. When the results are small, the serialize and unserialize function will do the job. Is there a way of going through this in other manner?
View Replies !
Passing More Than One Variable To The Next Page?
I've got a page with product info on it. The same page also has a recordset of variables. I've got a button which has been written using php something like: <? print"<a href="write_review.php?PID=$product_id">img etc...?> and I've got $product_id = $_GET['PID']; at the top of the page! This passes the product ID to the next page so that I can use it! How would I pass another variable too using the same button? I've tried just adding &title=$product_title, but it doesn't seem to work? I've already got $product_title = $_GET['title']; at the top of the page under the first one.
View Replies !
Passing An Array From One Page To Another?
Is it possible to pass an array from one PHP window to another? I have a form where some choices are made by checking boxes, a large number of boxes. And the results of the checks are held in an array. I would love to have the resulting query populate a new pop-up JS window, but I cannot figure out how to pass an array.
View Replies !
Passing The Variables To More Than One Page
I have an initial page 'page_one.php' that sends the data to another one - 'page_two.php' using form. It sends a couple of variables collected from the user input. Now....'page_two.php' has header function before any html that is either skipped or executed based on the user selection. If it doesn't come to header everything is fine, but if it does - header redirects 'page_two.php' to 'page_three.php'. Now, I want to be able to view all the selected variables in 'page_one.php' in my php code in 'page_three.php'. In another words, how do I pass the variables to page_three.php if it's not declared in action='...' located in 'page_one.php'?
View Replies !
Passing A Variable Into A Another Page
I have a list that comes in during a while statement: Jane john pete ..ect and i have a hyperlink so i can view their stats... and i want to past their name so i can get it in the next page...but the variable is not comming up: <a href=info.php?name=$name>".$name."[/url] this is what I get: http://localhost/mdo_main/info.php?name=
View Replies !
Passing These Values To Next Page!
I can't seem to get these values to pass to the next page, any ideas? I know this is normally simple but i'm lost with it now. Need some fresh eyes: Soil Level should be a number. I can echo it on the page, BUT when i pass it to the next page it's just blank. PHP Code:
View Replies !
Passing Through A Variable From Url To Page
I have a php landing page and I'm trying to use a tracking code that would let me dynamically pass through part of the url of this page (like the number 6264) to a point on the page, such as in part of a hyperlink that's posted on the page. Does anyone know if this is possible? Ideally, I want to be able to access this page using a query string/tracking code that would include a 4-5 character variable that could be anything really, and it would make whatever that variable is, show up at any point on the page through the use of a token. I want to pass this variable through in an affiliate link. This has gotta be a simple piece of code that does this. Does anyone know off-hand how someone would do this?
View Replies !
Passing Array To Another Page
I want to pass an array to another php page. Now, I know this can be done with SESSION. But I want to pass array something like page.php?arr=$myarray. Is it possible? If yes, please post example.
View Replies !
Passing A Variable To Another Page?
I'm writing a script for advertisers to signup to get a text link on my website. I'm using a verification page, to make sure they've entered in their information correctly. I need the data to go from signup.php --> verify.php --> complete.php. I'm able to get the data from signup.php --> verify.php with <form method="post" action="verify.php">, but how can I pass normal variables from verify.php --> complete.php?
View Replies !
Passing Value Trough A 3rd Page
I was looking on the web and I can't find what I'm looking for or I don't really understand. Let take the example of the login script. The user enter his user ID and password and then if it match redirect to another page. Now, when he click on a link he would then go to that page, how can I verify is user id and password again on the 3rd page and so on ? I know it's something easy but I'm don't understand this.
View Replies !
Passing Variables From One Page To Another
I need to take a set of variables from a form, pass them to another form, and finally collect all variables submitted into a final form, where it can be submitted. For instance, the first page asks the user which "web package" they like.. they select and go to another page, which says, "You selected the ___ package, now select your favorite design." They select there design, hit continue, and go to the final page that says, "You selected the __package, __design, and it costs $__ dollars (hidden values) Then they hit submit and all that info is sent via email.
View Replies !
Passing A Javascript Value To A New Page
I am needing to make a section in a form that allows for multiple check boxes to be selected and then and most importantly it has to be writen to a database . basicly I would like to be able to do is one of two things , the preferable is to check which boxes are ticked and then slot them into data1 data2 and data3 in the database my other alternative and less prefered is to put them all into one field and seperate the values with a / or , the script bellow pretty much does what i want except it echo's the responce in an alert when you click the output button what I need this script to do is run the script as I submit the form , and then pass the value's over to the processing page so that I can assign them to a variable and slot em into the database Code:
View Replies !
Passing Values To Next Page
I have a page that allows users to choose from checkboxes, each with text next to the three checkbox options. If users don't choose from one of the checkboxes then i don't want the text to appear on the next page. But if others have been chosen i want them to show. Maybe i need another elseif in the statement. Code:
View Replies !
Passing Info From One Page To Another
I have a dynamically generated list of check boxes with ids email1, email2, up to the end of the list of addresses. This list is then passed to the next page where all the addresses are concatenated and added to a database. At least that's the theory. I can't figure out how to dynamically get all the $_POST[emailx] variables, with x being 1, 2, to the end of the list.
View Replies !
Passing As URL Such As Page?id=100 To A 4 Script
I am passing variable such as page.php?id=100 to a php script. When I run the script with the id hard coded it works. It uses x template and displays information in the database just fine. It is just that I need to reprode this script times 21 and dont want to have 21 copies of the same script on the server. I need to be able to pass the variable and an id to the script so that I can use one script to do the job. I will also be using the same form 21 times. I just need the PHP to recognize the difference between the id's I pass to it for each page. Code:
View Replies !
Passing Objects Form One Page To Another
Is it possible to transfer objects derived from a class form one page to another? I made 2 testscripts: person.php ------------------------------------- <?php class person { private $_name; public function setName($name) { $this->_name = $name; } public function getName() { return $this->_name; } } $p = new person(); $p->setName("Jim"); $safep = urlencode(serialize($p)); header("Location:person2.php?data=".$safep); exit; ?> person2.php --------------------------------- <?php class person { private $_name; public function setName($name) { $this->_name = $name; } public function getName() { return $this->_name; } } $x = unserialize(urldecode($_GET['data'])); echo $x->getName(); ?> But this does not work for me....
View Replies !
Array Values Not Passing To Next Page
I have a search form which has list box where in the user could select multiple values and a text box for date field.When the user selects multiple selection, the query works fine and displays according to selection only on the first page, but when they hit the next page the query displays the results for all selection. I 'm displaying 25 records/page. But it works fine for the date field and the next , previous links display according to the date value. I 'm not sure why the value of the array is not passed. PHP Code:
View Replies !
Passing More Than One Word Variables To Php Page
i wrote a search page for my site (searching through a mysql database) but when i type in more than one word (eg "item three") in the search field it gets passed to the page as a single word ("item"). Are there any workarounds for this? the code is below.( houseproudlancs.co.uk/search.php ) <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- background="./images/background.jpg" --> <body bgcolor="#640000"> <?php $search_for = $_GET['for']; $search_category = $_GET['category']; global $search_for; global $search_category; global $the_items_description; global $does_contain_text; ?> <div align=center> <form action="http://www.houseproudlancs.co.uk/search.php" method="GET"> <br><table bgcolor="#EBEB96" cellpadding=6> <tr> <td> </td> </tr> <tr> <td> <div align=center> Search For: </div></td> <td> <div align=center> Category: </div> </td> </tr> <tr> <td> <INPUT name=for value=<?php echo ("$search_for"); ?>> </td> <td> <SELECT NAME=category SIZE=1> <OPTION <?php if ($search_category == "Search All Categories") { echo ("SELECTED"); } ?>>Search All Categories <OPTION <?php if ($search_category == "Floral Creations") { echo ("SELECTED"); }?>>Floral Creations <OPTION <?php if ($search_category == "Decorative Lighting") { echo ("SELECTED"); }?>>Decorative Lighting <OPTION <?php if ($search_category == "Kitchenware & Crockery") { echo ("SELECTED"); }?>>Kitchenware & Crockery <OPTION <?php if ($search_category == "Fancy Goods & Furniture") { echo ("SELECTED"); }?>>Fancy Goods & Furniture </SELECT> </td> <td> <INPUT TYPE=submit VALUE="Search"> </td> </form> <tr> <td> </td> </tr> </table> </div>
View Replies !
Passing Variable Between Functions On The Same Page
I have a function (below). The part I am confused abbout is the variable $cnt (in bold). I wish to use this variable in another function that is on the same PHP page, how can I pass the $cnt variable onto another function in the same page? I keep gettin the undefind variable message! Code....
View Replies !
Passing Checkbox Values To Another Page
What I want to do is pass multiple checkbox values from a form on an HTML page to another page (Thank you page) where it can be viewed if it was selected (checked). I know I need to "Get" the information from the quiry string after the information has been submitted but I'm lost on how to exactly set this up so it works properly. Code:
View Replies !
Passing A Php Variable When Opening New Page
I am working on a file directory listing and file editor. I have a index.php file which lists directory contents and a "create new file" link which pops up a new window to create a file within the working directory. I am popping up that new window with javascript and I'm not sure how to pass the variable containing the working directory as I do that. Code:
View Replies !
Passing Form Data Through A Page
I'm in the process of creating a new form that stores customer input into a MySQL database. What i'm attempting to do is allow them to fill out their data, and hit 'next' to go on to a file upload form. Upon completing that form and submitting, all information (including their data from page 1) is posted at the same time (so it's all under the same ID). What would be the easiest way to do this? Right now my submit file (submitquote.php) contains the following data (all on one page). Code:
View Replies !
Repeatly Passing Objects To The Same Page?
Let say I am trying to get a list of schools, and I provide a form for ONE school/page. If the user wants to add one more school, he/she can press "add" and it will loop back to the same php page and php script should construct an object "school" based on the data he/she entered in the form and add the object into an array. If the user has entered all the school infos, he/she can press "done" and the php script should flush the array of "school" objects into a db. My main question: how can I pass the array of objects back to the same page?
View Replies !
Passing Parameters To A Web Page Script
I posted this earlier and it disappeared from the NewsGroup I want to pass two parameters to a simple script running on my web server. The script "parpass.php" looks like this: <?php echo "The total number of parameters passed was: $argc "; echo "The parameters passed were: "; foreach (argv as $val) { echo "$val "; } echo " "; ?> I tried running this script by typing this in my browser window Code:
View Replies !
Passing Information To A New Page With A Submit Button
I've started creating scripts that allow for one page to have a form that data can be added to. A second page that allows some one else to view all the submissions that have been entered. This page also creates a submit button for each entry. Now what I need to do is make it so that only the entry for which the submit button is connected to is carried over to a third page. At this point using variables, each button gets a different name and value such as, button 1, button 2, button 3, ... When I click any of the buttons all the data from all the submissions get carried over to the new page instead of only the data that that button goes with. How do I write the code on the third page to carry over just the data that the button I click is related to? I'm using a flat file for the data entered into the first page. Glenn
View Replies !
Help Needed - Passing Values Between Two Loads Of The Same Page
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 'f' with values Ƈ' and ƈ' are used to distinguish calls from one form from those from the other. <html> <head><title>Database Access</title></head> <body> <form name="QueryForm" action="db2.php" method="POST" /> <input type="hidden" name="f" value="1" /> <input type="text" width="100" name="txtQuery" value="select * from license_master;" /> <br/> <input type="submit" name="Query" value="Query" /> <br/> </form> <?php $s = ""; $nl = "<br/>"; switch ($_POST['f']){ case Ƈ': $conn=odbc_connect('mysqldsnone','root','katipatan g'); $sql = $_POST['txtQuery']; $rs=odbc_exec($conn,$sql); echo "<table width="60%"> "; while (odbc_fetch_row($rs)){ $abbr=odbc_result($rs,"abbr"); $fullname=odbc_result($rs,"fullname"); $link=odbc_result($rs,"link"); echo "<tr> <td colspan="3" background="blue.png"> <p class="white-text">".$abbr."</p></td></tr> "; echo "<tr><td>".$abbr."</td><td>".$fullname ."</td><td><a href="".$link."">".$link."</a></td></tr> "; $s .= $abbr.",".$fullname.",".$link." "; //making the comma separated string here }
View Replies !
Passing This Radio Button Info To New Page.
I have my users choosing from several radio buttons on a page(page1). When they click "submit" they should be given a table of results on another page(page2). Depending on which one they choose an X will appear in the correct box. Code:
View Replies !
Passing 'var' Via GET And Then Populating Page (mysql)
I have a table with a column of numbers (random): 0000000001 0000000026 0000000059 0000000034 And I would like to link them to go to 1 specific template page. Then once on that page, the number that was clicked gets "posted" to the MySQL Query and the information for the page populated dynamically rather than having to have 4 different pages for each number (that's the way I'm doing it now). Code:
View Replies !
Passing Variables In Frame Page By Post Method
Is it possible to send variables by post method through a submit button to a frames page, and have all 3 pages in the frame pick up the variable using the $_request[var] ?In other words, I click on a submit button. in form action method call index.php the index page has a top, main, and a left frame.how do i get each one of those to receive the variable, when i can only sendit to one page? or is it possible to send it to more than one page, but only action to one page?
View Replies !
Populating Form From Database, Then Passing Results To Next Page
I have a multiple select input in a form that's being populated by a row from my database as such: <input type="checkbox" name="subm[]" value="$row[ID]"> That part is working fine as I can check the displayed page using View Source and see that the value is the correct row number from the database. It is then being submitted on a form by $_POST method to another page where I want to evaluate the checkboxes and display the contents of the entire row that corresponds to each value="$row[ID]" that have been checked. But I can't seem to get it to work. I'm having a problem passing the selected value. Can someone point me in the right direction? $query = ("SELECT * FROM `table`"); $result = mysql_query($query); print "<p>Data for Selections:"; print "<table border=2><tr><th>You chose:"; foreach ($_POST['subm'] as $value) { print "<tr><td>"; print "$row[ID]; "; print mysql_field_name($result, 1) . ": " . $row[name]."<br>"; print mysql_field_name($result, 2) . ": " . $row[address]."<br>"; print mysql_field_name($result, 3) . ": " . $row[city]."<br>"; print "</td></tr>"; print "</table> "; } if (!isset($_POST['subm'])){ print "<p>No matching entry "; } mysql_close();
View Replies !
Need Code To Find Last Page, And Passing All Form Variables
I need to be able to make some sort of php function to pull up the last page viewed so I can pass form varaibles to it etc, so the javascript function go.history(-1) wont work for this situation. After diving thru the php function dictionary for hours on end I'm at a loss for where to look, or what to look for. Also I was wondering if anyone knew an easy way to pass all form variables on to the next page rather than forwarding each manualy. This isn't all that important, but would make the code more efficiant.
View Replies !
Question On Passing A "variable" Back To A Calling Page
I have a php page that calls another php page to load a image from a database (mysql) in to the calling page. It works like this: first_view.php has <img src="image.php?img=5" width="200" border="1" alt="Image of Sunset"> the image.php opens the database and returns the image to the page (first_view.php). image.php can (does) also pull the title of the image being loaded to first_view.php out of the query where the image data is send back: Code:
View Replies !
Passing Values Directly To A New Page And Using Them To Update Values
I'm trying to pass values through from one page to the next by clicking on an image. When I click an image it passes through the values for prodId and shopName This is passed through to my admin_update.php where I want to populate a table with all of the details stored on the product that was clicked on. The values are being passed through ok but the table is not being displayed. I have another update page but with this page i am using a submit button which is passing through the details. I tried using this method again but because there is no submit button used (I am just clicking on a link/image) it is not working for me. Code:
View Replies !
Refresh Problem - Warning: Page Has Expired The Page You Requested Was Created Using Information
i got two php page at the movement, which they called edit2.php and edit3.php. when i submit a form from edit2.php to edit3.php, then i could not come back from edit3.php to edit2.php. Warning: Page has Expired The page you requested was created using information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you. To resubmit your information and view this Web page, click the Refresh button. Code:
View Replies !
Page Expired After Going Back From Del. Pageto Form Page Where Comment Is Submitted..
i've made a submit comment form with php and mysql, the form has an action to itself with a hidden var like this: input type=hidden action=add When i delete a comment on the page i go to a page called delete.php3 and there is a link with a javaline which goes -1 back in my history.. When ive added a comment, the comments page contains action=add and when i delete a comment, i want to click on the link to go back to the comment page, but then, it doesnt work and it says: Page has expired. I wondered how to deal with this kind of problems........
View Replies !
Page Has Expired Message In Between The Php Page When I Click Back In Explorer Menu
I have a php script page, which is basically quiz. Visitors (after login in with their email address) are supposed to answer each question, and when they click the button at the bottom, the next page will show which problems they got right or wrong. Now my visitors, after seeing some problems they got wrong, click Back button at the Explorer menu, and if they do, they get the below message: ========================= Warning: Page has Expired The page you requested was created using information you submitted in a form. This page is no longer available. As a security precaution, Internet Explorer does not automatically resubmit your information for you. To resubmit your information and view this Web page, click the Refresh button. ======================== Below are the script that I am using. This scripts are after initial login page, which asks for visitor's email address. I have authorized visitors already in my MySQL table, and only the visitors whose email address is in my MySQL table are allowed to login......
View Replies !
|