Daniel Brown wrote:
On 8/10/07, Jason Pruim <[EMAIL PROTECTED]> wrote:
Hi All :)
Hope you're not getting sick of my questions as of late, but I keep
getting closer and closer and thank you all who have helped me in the
past! "The only reason I can see this far is I am standing on the
shoulders of giants" don't know who said that but I like it :)
Anyway... Onto the question...
I think I'm just going crazy as it's been a busy week for me, but I
can't figure out how to do this. What I am attempting to do is, I
have a webpage(Don't we all?) that calls info to be displayed from a
I want to be able to sort that info so my sql query looks like:
"Select * from current order by '$order';" and $order is populated by
a GET when they click on a link: "<A href=index.php?order='Last'>Sort
by last name</A>" Now... the whole PHP page is being included in
a .shtml page to actually display it and make it look purrdee :)
How do I get it to resort the info and include the new sort on the page?
I'm not sure if this has anything to do with it but:
$order = $_GET['order']; <------Line 6
[Fri Aug 10 10:42:04 2007] [error] PHP Notice: Undefined index:
order in /Volumes/RAIDer/webserver/Documents/tests/legion/index.php
on line 6
Any help will be greatly appreciated.. And if it solves the problem
I'll name some of my kids* after you!
*Subject to approval of the Wife :)
3251 132nd ave
Holland, MI, 49424
Remember to clean that input before you sit down at the table, there, boy!
It's safe to ignore the `Undefined index` notices. That will just
appear if a variable is referenced without first being instantiated or
defined. No biggie, just put this at the head of your code:
ini_set("error_reporting",E_ALL & ~E_NOTICE);
Bad Dan *slap*. Ignoring notices may be detrimental to your health
and/or well-being. Better to initialise it with a default if it has not
been set in the request.
if (!isset($_GET['order'])) $_GET['order'] = 'Last';
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php