Home > Archive > PHP Language > May 2004 > Newbie Question: Disclosure Triangle?
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Newbie Question: Disclosure Triangle?
|
|
| Vik Rubenfeld 2004-05-18, 5:31 pm |
| I'd like to have a screen with a list of items, for example, a list of
folder names. There would be a triangle on the left of each folder name
pointing to it. When the user clicks the triangle, the list opens up to
reveal a sub-list of filenames contained in that folder.
For the purposes of my project, I don't have to deal with sub-folders.
I know how to get PHP to handle the database end of things, and produce
HTML that shows the list, and then later, the sublist. I just need to
figure out how to get the info about which triangle was clicked, to a
PHP app, that can then send the updated HTML screen to the user's
browser.
What's the correct way to have PHP respond to the click on the triangle?
Should the triangle be a submit button, or some other type of button?
Thanks in advance to all for any thoughts on this!
-Vik
| |
| johannes m.r. 2004-05-18, 5:31 pm |
| Why not use the query string for this? I.e. the "triangles" are normal
links (or linked images or whatever) in the form of
yourscript.php?folder=foldername
You can get the value of folder in your PHP script by accessing
$_GET['folder']
Or did I understand something wrong? :-)
Regards,
johannes
| |
| Vik Rubenfeld 2004-05-18, 6:30 pm |
| johannes m.r. <psychosos@gmx.at> wrote:
> Why not use the query string for this? I.e. the "triangles" are normal
> links (or linked images or whatever) in the form of
> yourscript.php?folder=foldername
> You can get the value of folder in your PHP script by accessing
> $_GET['folder']
This sounds really good. I'm going to research this and post further if
I have more questions. Thanks very much!
-Vik
|
|
|
|
|