Losing 'page' data


Posted on 16th Feb 2014 07:03 pm by admin

I have this code that allows me to update my database. But after updating, I lose the $_GET['page'] value in the browser. I need this value because it is passed when I go to other pages on the site.

Code: echo ($_GET['change'] == 'Garage_Type') ?
'<form method="get" action="' . $_SERVER['PHP_SELF'] .
'">
<select name="Garage_Type">
<option value="Attached">Garage </option>
<option value="Detached">Detached Garage </option>
<option value="Attached Carport">Carport </option>
<option value="Detached Carport">Detached Carport </option>
<option value="None">None </option>
</select>

<input type="submit" name="submit" value="Update DB!" /><input type="hidden" name="id" value="' . $this->_ID . '" /><input type="hidden" name="col" value="Garage_Type" /></form>' . '</td></tr></table></td></tr><tr><td colspan="3" bgcolor="#CCCCCC"></td></tr><tr><td>':
$this->_DATA['Garage_Type'] . '</td></tr></table> </td><td><a href="' . $_SERVER['PHP_SELF'] . '?change=Garage_Type&id=' .$this->_ID .'&page='.$_GET['page'].'&orderid='.$_GET['orderid'].'&asc='.$_GET['asc'].'">Edit</a>' .
'</td></tr><tr><td colspan="3" bgcolor="#CCCCCC">';

No comments posted yet

Your Answer:

Login to answer
138 Like 39 Dislike
Previous forums Next forums
Other forums

how can we add data from dynamic fields to mysql db in php
i have a script which i found on the internet. i modify that script according to my needs. what is i

Warning: session_start() [function.session-start]: Cann.....
hi, can someone help me with this? I keep getting this error....

Warning: session_start() [fu

How to use Substr
I want to check for the word CATEGORY: inside a string which can be CATEGORY: ITEM
and remove the

Add a sign-up feature to a flat file login script
I'm working on a flat file login script and I would like to add a sign-up feature to it with a email

Compare user input to flat file data
Help...Am a complete newbie to programming so my code is prolly quite long. Am trying to verify a us

error checking breaking my code
Hi there, OK first of all, big apologies for what I assume is really fundamental errors in the struc

Firefox displaying PHP source code??
Currently testing a site thats almost built, am going to be including php on a sidebar on all pages

login box shows up again after logging in 2nd login works
Hello,

I am having trouble on my site Lockerz.rack111.com where when you login the login box

Inter Company -- Resources Related Billing (Services Industry)
Hello,

My company has a scenario where:
Company A bills Company C for INTER (cross

Get Total From While Loop
I'm trying to get the total for each product and add them for a Grand Total to list outside the loop

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash