OK, so I have a website (http://www.brianellisrules.com).
On this website, I have various stories, some with pictures.
I'm in the midst of a new story and I'm trying something new with php. I'm about halfway there...
Here's what I'm thinking. I have a story... a little writeup. Throughout the story are various links to pictures. Rather than having the person click the links (and leave the story) I want to have them stay put... but, I don't want the pictures showing up when the page loads. So, here's what I devised...
This way, there's the text... the person reads it, the click the link and the picture appears below the line. This actually works! Sort of!
Right now the page I'm working on has more than one picture, so once another link is clicked, the previously shown picture disappears. This is annoying because the page reloads and the text jumps around and makes it hard to follow.
Here's a sample:
http://www.brianellisrules.com/temp/sample.php
Any ideas for a way to get the pics to stay once they're clicked (and other images/links are clicked)?
On this website, I have various stories, some with pictures.
I'm in the midst of a new story and I'm trying something new with php. I'm about halfway there...
Here's what I'm thinking. I have a story... a little writeup. Throughout the story are various links to pictures. Rather than having the person click the links (and leave the story) I want to have them stay put... but, I don't want the pictures showing up when the page loads. So, here's what I devised...
PHP:
<p>Here's a nice picture of me... Damn, I was a <a href="?pic=cutekid">cute kid</a>.</p>
<?php
if ($pic==cutekid) {
echo ("<center><img src=\"picture.jpg\"></center>");
}
?>
Right now the page I'm working on has more than one picture, so once another link is clicked, the previously shown picture disappears. This is annoying because the page reloads and the text jumps around and makes it hard to follow.
Here's a sample:
http://www.brianellisrules.com/temp/sample.php
Any ideas for a way to get the pics to stay once they're clicked (and other images/links are clicked)?