Connecting Tech Pros Worldwide Help | Site Map

gallery glitch

anfetienne's Avatar
Needs Regular Fix
 
Join Date: Feb 2009
Location: UK
Posts: 356
#1: Jun 8 '09
hi, i've got a flash gallery which i've paid for. Im using swf object to import vars to the gallery....the var being imported is a html address to specify the location of files and folders. The problem is that the gallery detects the thumbnails and loads the 1st image but once i click on another image it wont load, i don't know why it it doing this and as it loads the thumbnails which are in the same location it shouldn't have a problem displaying the full-size images. here are the codes in step from swfobject.

Expand|Select|Wrap|Line Numbers
  1.                             <div id="flashgallery"><script type="text/javascript" src="http://theauctionwinners.com/resources/temp/swfobject.js"></script>
  2.  
  3. <div id="flashcontent">
  4.   This text is replaced by the Flash movie.
  5. </div>
  6.  
  7. <script type="text/javascript">var so = new SWFObject("http://theauctionwinners.com/resources/upload/99708922/gallery.swf", "gallery", "518", "536", "8", "#FFFFFF");
  8.    so.addParam("quality", "high");
  9.    so.addParam("wmode", "transparent");so.addVariable("tempURL","http://theauctionwinners.com/resources/upload/99708922/");   so.write("flashcontent");
  10. </script>  
  11.  
this is the actionscript that processes the gallery
Expand|Select|Wrap|Line Numbers
  1. stop();
  2. trace( tempURL );
  3. //specify the url where folder is located below (if applicable)
  4. toadd=tempURL;
  5. t = 0;
  6. l = 0;
  7. theside = 1;
  8. galxml = new XML();
  9. galxml.load(toadd+"gallery.xml");
  10. galxml.ignoreWhite = true;
  11. galxml.onLoad = function(success) {
  12.     if (success) {
  13.         maxnum = galxml.firstChild.childNodes.length;
  14.         for (n=0; n<maxnum; n++) {
  15.             specs = galxml.firstChild.childNodes[n];
  16.             //TEXT FOR SIDE NAV
  17.             duplicateMovieClip(side.thumbs.thumbsb, "thumbs"+n, n);
  18.             thumbclip = eval("side.thumbs.thumbs"+n);
  19.             thumbclip._x = n*100;
  20.             thumbclip.thetitle = specs.attributes.name;
  21.             thumbclip.thecaption = specs.attributes.caption;
  22.             thumbclip.thenum = n+1;
  23.             thumbclip._alpha = 100;
  24.             loadMovie(toadd+"images/"+(n+1)+"b.jpg", thumbclip.thumbload.thumbload2);
  25.             play();
  26.             side.thumbs.thumbsb._visible = false;
  27.         }
  28.     }
  29. };
  30. mainperc.onEnterFrame = function() {
  31.     if (mainperc.perc<98) {
  32.         mainperc._alpha += 5;
  33.     }
  34.     mainperc.perc = Math.round(l/t*100);
  35.     mainperc.perctext = mainperc.perc+"%";
  36.     mainperc.ltext = "OF THUMBNAILS LOADED ("+Math.round(t/1024)+"kb)";
  37.     if (mainperc.perc>98) {
  38.         //mainperc._alpha -= 5;
  39.     }
  40.     if (mainperc._alpha<-50) {
  41.         delete mainperc.onEnterFrame;
  42.     }
  43. };
  44.  
  45.  
  46. var lvContent:LoadVars = new LoadVars();
  47. lvContent.load("http://myhost.com/myvarstoflash.php?username=dotbart");
  48. trace("Who: " + lvContent.who);
  49. //Outputs: Who: dotbart
  50.  
here is a link to an example of the gallery
example link
anfetienne's Avatar
Needs Regular Fix
 
Join Date: Feb 2009
Location: UK
Posts: 356
#2: Jun 30 '09

re: gallery glitch


anybody have any idea why?
anfetienne's Avatar
Needs Regular Fix
 
Join Date: Feb 2009
Location: UK
Posts: 356
#3: Jul 7 '09

re: gallery glitch


can someone please point me in the right direction to solving this problem?

my guess is that i have to put in the xml the location of each image but as i dont know actionscript to well i wouldn't know if this is correct or not
Reply


Similar Flash / Actionscript bytes