PDA

View Full Version : Need some basic help



DWinsauer
Jan 19th, 2007, 08:19 PM
On this page I have a box on the right side. It contains 5 questions, each one is an image and will be turned into a link.

When I click question1.jpg, I would like answer1.jpg to show at the bottom, without the entire page reloading. The same goes for the other questions. Any help would be appreciated.

david_kw
Jan 19th, 2007, 09:02 PM
Do you have a sample of what your html looks like now? And what does "at the bottom mean"? Do you mean at the bottom of the jpg or at the bottom of the page?

david_kw

DWinsauer
Jan 19th, 2007, 09:05 PM
I mean at the bottom of the white box on the right. Here's the HTML.



<tr>
<td rowspan="16"><div align="center">
<table width="80%" height="292" border="0" cellpadding="1" cellspacing="1">
<tr>
<td><img src="images/question1.png" width="165" height="11"></td>
</tr>
<tr>
<td><img src="images/question2.png" width="227" height="26"></td>
</tr>
<tr>
<td><img src="images/question3.png" width="179" height="8"></td>
</tr>
<tr>
<td><img src="images/question4.png" width="141" height="11"></td>
</tr>
<tr>
<td><img src="images/question5.png" width="220" height="11"></td>
</tr>
<tr>
<td height="110"><img src="images/answer1.png" width="282" height="130"></td>
</tr>
</table>
</div></td>

david_kw
Jan 19th, 2007, 09:53 PM
I don't know where the bottom of the white box on the right is, but from your example it looks like you want to add another row to your table with the answer in it. Correct? Or do you want to replace the answer image and only show one answer at a time?

david_kw

DWinsauer
Jan 19th, 2007, 10:19 PM
I ended up figuring out the solution via Switch / Case in php. I was trying to use that originally, but I was told in the PHP forums to use javascript =p

david_kw
Jan 19th, 2007, 10:26 PM
Well javascript is good if you don't want to hit the server. I just didn't fully understand what you wanted. :)

Glad you figured out something you are happy with though.

david_kw