new php
| From: | Blue Presley | Date: | Thu, 13 Jun 2002 02:56:26 +0000 |
| Subject: | new php | ||
| Groups: | php.smarty.general | ||
| Request: | Send a blank email to php-smarty-general+get-4826@lists.php.net to get a copy of this message | ||
i'll apologize in advance for this being a bit off topic, but i've tried to incorporate a
bit of smarty into it so as to not totally be off base....
okay.. in the past i've enjoyed being able to pass variables as name/value pairs in the URL.
this was essential for getting appropriate data from my SQL database. here is an example of the
code.
getDetails.php?id=1
and of course, this would get data associated with that particular table entry.
anyway, as of version 4.1.0, I register_globals has been turned off and it's strongly suggested
that it not be turned on for security reasons.. okay, fine, but now i can't pass name/value
pairs in the url. so part of my question is, I have to be able to reference the IDs for an entry.
If i can't use name value pairs, then how do I do it?
now here is where smarty comes in. I'm thinking that i can create a multidimensional array out
of $_GLOBALS[] and assign the id to each one. then i could have something like
getDetails.php?id=<?php echo $_globals[id][x]; ?>.. but how do i assign that to a Smarty
variable to use in the template?
all thoughts appreciated.. thanks! :)
blue