Help on this one, URGENT!!!

  • Hi everyone,
    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:


    test.jpg
    blah blah
    test_tn.jpg


    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 click here to open in popup and have this link to open the node's image?

    Please somebody help! :hurt:


  • heheh
    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


  • Heres an idea, I can't back it up with code at the moment, but it may be useful nonetheless.

    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


  • Took a look at the site, it looks good.

    Glad I could help get your problem solved

    -Lem


  • great, thanks, I'll check this method out right away and see what goes on.
    I'll keep ya posted! :)


  • I used text.jpg because thats the name of the picture example you gave above, where test.jpg was used, it would have been replaced with whatever image name the user is looking at.

    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


  • Don't know if you'll look at this, but I somehow managed to have it work, I'm not sure how I did that, but i truly hope I won't have to do that again.
    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 do my web work and education at home, on my own computer.
    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


  • thanks man, i'll check it out right away :)
    keep up the cleaning! ;)


  • hmmm
    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


  • won't get it to work, the mf....







  • #If you have any other info about this subject , Please add it free.#
    Your name:
    E-mail:
    Telphone:

    Your comments:


    If you have any other info about Help on this one, URGENT!!! , Please add it free.