[RESOLVED] Can you help with this problem (display data without reload)?
Hello
I am making a photo album for my website. Right now (as the photo shows) http://staging.moonsofneptune.com/screenshot.gif it loads 9 images at a atime from a specified folder. when you click on a photo it runs a javascript script which puts the larger copy of the image into the left box. The page doesnt reload and you can still see the page your on.
I have writen things into the meta tags of the images, like who took it, when, the size, a little description. my old photo album script showed this becuase I had every image open in a new window. when i changed to the javascript i cant get that to work anymore.
does anyone know how i can get the meta data from the images larger copy when you click on the small image to the right of the screen? I dont want the page to reload becuase then the images reset to page 1 and everything. I can explain more if you need me to. Thank you.
Edit: i forgot to add, I am using PHP to read through the folders and images and it dynamically creates the pages and listings.
Re: Can you help with this problem (display data without reload)?
What do you mean when you say "The page doesnt reload and you can still see the page your on."?
btw: cute kitty :)
Re: Can you help with this problem (display data without reload)?
She is sute, thank you. My old script in php...
It would display a block of up to 12 photos at a time. When you clicked on a photo, it reloaded (passing variables to itself) and instead of displaying the 12 photos, it just displayed the one you clicked. This allowed me to display the exif data for the photo.
now my script loads 9 photos and when you click on one, it uses javascript to display the big photo in the left of the screen. This way the page doesnt keep reloading. it loads 1 time and they can view all 9 photos in thier large format instead of reloading every photo.
i just dont know how to read the exif data when they click the photo. Here is the code I use,
Code:
<script>
function showPicture(filename){
document.images["PictureBox"].src = filename;
}
</script>
'The link
<a href=\"Javascript:showPicture('photo_album/$subcatagory/$folder/$entry')\">
Re: Can you help with this problem (display data without reload)?
what "exit data" do you need and why?
Re: Can you help with this problem (display data without reload)?
instead of using a database, I write the data about the photo into those fileds. that way anyone can read it when i give people copies. I use the date it was taken, the size/dimensions, the copyright (who ever took the photo) , and the description filed (to give a description about the photo)
Re: Can you help with this problem (display data without reload)?
Where do you get the picture data from and how do you update it?
Re: Can you help with this problem (display data without reload)?
I forget the program I use to set the data but this is what i used in my old script.
Code:
$imagename = "photo_album/" . $subcatagory . "/" . $folder . "/" . $picturename;
$exif = exif_read_data($imagename, 0, true);
$filename = $exif['FILE']['FileName'];
$filesize = $exif['FILE']['FileSize'];
$imgwidth = $exif['COMPUTED']['Width'];
$imgheight = $exif['COMPUTED']['Height'];
$comments = $exif['COMPUTED']['UserComment'];
$copyright = $exif['COMPUTED']['Copyright'];
$tempSize = ByteSize($filesize);
somehow i would like to get this data when you click on the small image t the right without reloading the page.