Skip to main content
Participant
February 25, 2009
Question

Using PHP MySQL to load data into div

  • February 25, 2009
  • 1 reply
  • 572 views
I have one page with mulitple images and one hidden div. When one of the images are selected, the hidden div will appear and the div will be loaded with dynamic data based on the button selected. Can anyone give me any help on how to accomplish retrieving a database record without using a url parameter?
This topic has been closed for replies.

1 reply

Inspiring
February 25, 2009
For the image to be clicked, the page will already have been fetched from
the server. Since server-scripting only executes on the server, you have
missed your opportunity to use server-scripting to retrieve the data. And
since you don't want to use a URL variable, you would have to use a cookie
or a session variable instead.

Have the click on the image first set a cookie/session variable containing
the information for which record to retrieve, and then reload the same page,
which will check the value in the cookie/session variable to load the
desired record from the database, and populate the div.

If you don't want to reload the page then you will have to use something
like SPRY/AJAX.

--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
==================


"green tomato" <webforumsuser@macromedia.com> wrote in message
news:go2n9v$op1$1@forums.macromedia.com...
>I have one page with mulitple images and one hidden div. When one of the
>images
> are selected, the hidden div will appear and the div will be loaded with
> dynamic data based on the button selected. Can anyone give me any help on
> how
> to accomplish retrieving a database record without using a url parameter?
>