I really need help on this one.
I have this movieclip (it is actually contained into another mc, but this doesn't matter at this time), which loads thru the usual XML some pictures, their captions, their thumbnails and everything.
So far so good, everything works perfectly fine.
The people I'm doing this for though want to be able to open a popup window for each of the pictures present in the xml file, that btw looks like this:
They want this to be done so that you can email directly the picture you want to someone using windows' menu.
Here's where this should be done:
http://www.actual-design.com/bross/contractGallery.html
I'm a bit frustrated...
Can I simply add a node in the xml file, like
Please somebody help! :hurt:
wouldnt wanna have you extra job, but tell you what.
I'm working on it tonite (it's 11.50PM here in italy), and should it happen that I don't figure this out, i'll post the fla. Gotta warn you though, it's quite a mess.
Will clean it up in case I post it.
Thanks a billion for your help anyway, will let you know.
C
Instead of trying to add additional nodes to the xml file, why not go this approach:
Add code either on the timeline,pic next previous, thumbnail buttons, etc..
that constantly updates a variable called currentPicture
currentPicture will have a value similar to "test.jpg"
Then you can have a large, invisible button over the place where the user previews the image, so that when the click on the image, a popup window opens up based on what image is selected.
You could probably just write a button action similar to:
on (release) {
pictureURL = "http://www.yourwebsite.com/images/" + currentPicture + ".html"
getURL(pictureURL, "_blank");
}
That code will open up a html document located like
http://www.yourwebsite.com/images/test.jpg.html
I'm pretty sure that multiple "."s are allowed in urls, I've seen them often enough, especially with phishing site urls.
Anyway with that idea, you could leave the XML alone, just have the variable currentPicture constantly being updated when the user clicks on a new picture button, and then that actionscript on a newly added button placed over the picture preview
Anyway, that was all off the top of my head, seems easier then modifying your working gallery xml related code just to add a new node, just to end up using that node to create something similar to my currentPicture variable and button setup
Hope thats helped, whether it solves your problem or gives you a different perspective on it.
-Lem
Glad I could help get your problem solved
-Lem
I'll keep ya posted! :)
As for:
Basically, how do I tell flash which picture out of the thumbnails the visitor is looking at?
Try this.
Change the code involving telling the viewer what picture to display, so that just after it tells the viewer to display so-and-so jpeg it sends the name of so-and-so jpeg to _root.currentPicture. Thats it, its all you have to do, then
use the button code i provided
If you provide a .Fla file for your site, I may be able to write the whole thing for you tomorrow, can't today, gotta go.
-Lem
I'll pm you the link to the whole site so that you see it running on the big thing.
Thanks again for your help, wouldn't have made it out w/out your hints...
I'll take my time to study the fla you sent me, it's pretty much well done, kind of a pro!
I'm still working on good clean computer file organizational habits.
But I still tend to let things like my downloads folder fill up without sorting.
Anyway, I'm cleaning up a 70 gigabyte folder full of stuff (misc stuff, probably half trash)
and I found some kind of Flash xml based popup gallery.
While it doesn't suit all of your needs, it does contain thumbnail images of xml defined pictures and when you click the thumbnail image a popup window opens.
I haven't looked at the code myself. I have to continue cleaning that folder (3 gigs left on HD, not good)
But I thought I'd upload it here for you.
No idea where I got it, who made it, or when I downloaded it.
DL here: http://www.albertaintegrated.com/popupgallery.zip
-Lem
keep up the cleaning! ;)
it sounds easier than it probably is.
It of course shows i'm still a beginner at flash, especially with AS2, but still I'm trying...
I totally follow you on what you said, it makes perfect sense in my head.
Based on what pic the viewer has opened, the big-button will lead to a different variable, loading the html popup.
There's a few things I am not sure of though.
currentPicture has to be given a value. Why would I use "test" as its value?
Basically, how do I tell flash which picture out of the thumbnails the visitor is looking at?
i can see the light, but it's still pretty much far away...
Thanks anyway 4 your time! :)
Carlo
#If you have any other info about this subject , Please add it free.# |