Visualizzazione dei risultati da 1 a 6 su 6
  1. #1
    Utente di HTML.it
    Registrato dal
    Dec 2001
    Messaggi
    390

    realizzazione slideshow

    Salve a tutti. Sarei interessato ad inserire in un sito che sto facendo uno slideshow con immagini e testo, tale da avere un link ipertestuale alle sezioni del mio sito per ogni schermata che compare. In parole povere, vorrei qualcosa del tipo questo
    http://www.frontpageslideshow.net/content/view/14/33/
    che è disponibile però per i vari cms.
    Esiste qualcosa di "prefabbricato" da inserire all'interno di un swf??
    grazie a tutti friends!
    Date a Cesare quel che è di Cesare,
    tutto il resto a me!!

  2. #2
    Utente di HTML.it
    Registrato dal
    Dec 2001
    Messaggi
    390
    up!!!
    Date a Cesare quel che è di Cesare,
    tutto il resto a me!!

  3. #3
    "Come faccio a spiegare a mia moglie che quando guardo fuori dalla finestra sto lavorando?"

    (J. Cornard)

  4. #4
    Utente di HTML.it
    Registrato dal
    Dec 2001
    Messaggi
    390
    ottimo. ci impiegherò del tempo per personalizzarlo, ma va bene!
    una cosa: nel mio fla ho inserito un mc vuoto, chiamato news_mc. Nel primo frame del filmato file ho inserito la funzione
    news_mc.loadMovie("newsBox.swf");
    questo mi comporta che viene caritato l'swf, ma il newsBox è come se non prendesse nessun parametro esterno (del tipo non carica le immagini, non ci sono animazioni, il testo è costantemente "undefined"), mentre se apro direttamente newsbox.swf, questo viene caricato senza alcun errore.
    why???
    Date a Cesare quel che è di Cesare,
    tutto il resto a me!!

  5. #5
    Utente di HTML.it
    Registrato dal
    Dec 2001
    Messaggi
    390
    up!!
    Date a Cesare quel che è di Cesare,
    tutto il resto a me!!

  6. #6
    Utente di HTML.it
    Registrato dal
    Dec 2001
    Messaggi
    390
    ho fatto una prova, ovvero: invece di caricare l'swf con loadmovie, ho creato un movieclip all'interno del quale ho inserito i frame dell'swf che volevo caricare, e ottengo lo stesso errore. se invece inserisco i frame direttamente nello stage, tutto va bene.
    le azioni sono:

    frame1
    codice:
    #include "mc_tween2.as"
    Stage.showMenu = false;
    Stage.scaleMode = "noScale";
    _global.playStat = "";
    _global.p = 1;
    _global.total = 4;
    _global.times = 0;
    _global.gg = 0;
    _global.galleryNo = 0;
    _global.howmany = 0;
    _global.should = 0;
    ///////////////////////////////////////////////////////////
    // EDIT BELOW THIS LINE
    var slideTime:Number = 2; //Seconds each slide displays for
    var folderPath:String = "http://www.lewi-p.co.uk/xmlReader/"; //Change to desired folder
    var emailStat = false; //Enable email function, true/false
    frame2
    codice:
    this.onEnterFrame = function() {
    	if (_root.getBytesTotal() == _root.getBytesLoaded()) {
    		this.onEnterFrame = null;
    		gotoAndStop("loadXML");
    	}
    };

    frame3
    codice:
    stop();
    var arrMenu:Array = new Array();
    var arrItem:Array = new Array();
    //
    function loadXML(loaded) {
    	if (loaded) {
    		var xmlRoot = this.firstChild;
    		_global.galleryNo = xmlRoot.childNodes.length;
    		for (m=0; m<galleryNo; m++) {
    			_global.items = 3;  //numero di elementi
    			arrMenu.push(xmlRoot.childNodes[m].attributes.name);
    			for (i=0; i<items; i++) {
    				var descString:String = unescape(xmlRoot.childNodes[m].childNodes[i].childNodes[1].firstChild);
    				//Uppercase Main Title
    				var xString1 = unescape(xmlRoot.childNodes[m].childNodes[i].childNodes[0].firstChild);
    				var my_xml1:XML = new XML(xString1);
    				var my_node1:XMLNode = my_xml1.childNodes[0];
    				var titleString = my_node1.toString().toUpperCase();
    				//
    				var imageString = xmlRoot.childNodes[m].childNodes[i].childNodes[2].firstChild;
    				var linkString = xmlRoot.childNodes[m].childNodes[i].childNodes[3].firstChild;
    				arrItem.push(new Array(titleString, descString, imageString, linkString));
    			}
    		}
    		gotoAndStop("start");
    	} else {
    		trace(xmlFile+" not loaded!");
    	}
    }
    xmlData = new XML();
    xmlData.ignoreWhite = true;
    xmlData.onLoad = loadXML;
    xmlFile = "slideShow.xml";
    xmlData.load(xmlFile);

    frame4
    codice:
    stop();
    function setLink() {
    	for (i=0; i<4; i++) {
    		this.container["btn"+i].gotoAndStop("off");
    		this.container["btn"+i].enabled = true;
    	}
    	this.container["btn"+p].gotoAndStop("on");
    	timer.timeBar.xSlideTo(-497, 1, "easeInOutQuint", 0, function () {
    		if (playStat == "yes") {
    			callTime();
    		}
    		mainWindow.playPause.enabled = true;
    	});
    	linkBtn.onRelease = function() {
    		getURL(arrLink[p-1], "_self");
    	};
    	mainWindow.mainText.gotoAndPlay(1);
    }
    function nextPic() {
    	if (p<items) {
    		_global.p++;
    		xVar = mainWindow.content._x;
    		mainWindow.content.xSlideTo(xVar-722, 1, "easeInOutQuint");
    	} else {
    		
    		mainWindow.content.xSlideTo(0, 1, "easeInOutQuint", 0, function () {
    			_global.p = 1;
    			changeChannel();
    			var checker:Number = Number(_root.arrMenu.length*4)-4;
    			if (gg == checker) {
    				_global.gg = 0;
    			} else {
    				_global.gg += 4;
    			}
    			
    			
    		});
    	}
    	setLink();
    }
    
    
    function changePic() {
    	xVar = mainWindow.content._x;
    	goto = 722-Number(p*722);
    	timer.timeBar.stopTween("_x");
    	mainWindow.content.xSlideTo(goto, 1, "easeInOutQuint");
    	setLink();
    }
    function callTime() {
    	timer.timeBar.xSlideTo(0, _root.slideTime, "linear", 0, function () {
    		mainWindow.playPause.enabled = false;
    		_root.nextPic();
    	});
    }
    //
    function createButtons() {
    	for (i=0; i<items; i++) {  
    		mc = container.attachMovie("itemBtn", "btn"+(i+1), i);
    		mc.headline = arrItem[Number(_global.gg+i)][0];
    		mc._y = i*58;
    		mc.id = i+1;
    	}
    	changePic();
    }
    //
    function changeChannel() {
    	for (m=0; m<_root.arrMenu.length; m++) {
    		var id = m*4;
    		_root["menuBtn"+id].gotoAndStop("off");
    		_root["menuBtn"+id].enabled = true;
    	}
    	_root["menuBtn"+gg].gotoAndStop("on");
    	_root["menuBtn"+gg].enabled = false;
    	_root["menuBtn"+gg].swapDepths(this.getNextHighestDepth());
    	createButtons();
        preloadImages();
    }
    function createMenus() {
    	var fontButton:TextFormat = new TextFormat();
    	fontButton.font="skyfont", fontButton.size=14, fontButton.color=0x666666, fontButton.leading=-4;
    	//
    	var xPos:Number = 1;
    	for (i=0; i<arrMenu.length; i++) {
    		mc = attachMovie("menuBtn", "menuBtn"+i*4, this.getNextHighestDepth(), {_x:xPos, _y:1});
    		mc.id = i;
    		mc.buttonNo = i*4;
    		var findLength:Object = fontButton.getTextExtent(arrMenu[i]);
    		var titleLength = findLength.textFieldWidth+2;
    		xPos += titleLength+15;
    	}
    	changeChannel();
    }
    //
    function preloadImages() {
    	timer.timeBar.stopTween("_x");
    	_global.howmany = 0;
    	var xPos:Number = 0;
    	//
    	for (i=0; i<items; i++) {
    		this.container["btn"+i].enabled = false;
    		_root.mainWindow.content["cont"+i].removeMovieClip();
    		mc = _root.mainWindow.content.attachMovie("cont", "cont"+i, _root.mainWindow.content.getNextHighestDepth(), {_x:xPos, _y:0});
    		mc.photo = _root.arrItem[_global.gg+i][2];
    		xPos += 722;
    	}
    	this.onEnterFrame = function() {
    		if (howmany == items) {
    			setLink();
    			this.onEnterFrame = null;
    		}
    	};
    }
    createMenus();


    helpppppppppppppppppppppp
    Date a Cesare quel che è di Cesare,
    tutto il resto a me!!

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.