Visualizzazione dei risultati da 1 a 10 su 10

Discussione: verifica popup

  1. #1

    verifica popup

    ciao a tutti

    utilizzo fl 8


    ho un swf principale dove sul secondo Frame inserisco

    MovieClip.prototype.popup = function (nome,titolo,lar,alt,x,y,feat){
    getURL("javascript:window.open('" + nome + "','" + titolo + "','width=" + lar + ",height=" + alt + ",screenX=" + x + ",left=" + x + ",screenY=" + y + ",top=" + y + "," + feat + "');void(0);");
    }
    poi ho un tasto in un filmato swf caricato con loadmovie dove inserisco
    on (release) {
    apriPopupCentrata('zuppa.html', '', 550, 450, 'status=no, toolbar=no, locationbar=no, location=no, menubar=no, scrollbar=no, resizable=no');
    }


    non devo inserire niente nel html
    perkè nn funziona? :master:
    Sei grandeeeeeeee
    http://www.vitoloweb.net

  2. #2

  3. #3
    Utente di HTML.it L'avatar di and80
    Registrato dal
    Mar 2003
    Messaggi
    15,182
    un paio di cose

    1. dove provi il filmato? (ricorda che per funzionare il richiamo devi provarlo/usarlo dentro al browser)
    2. prova a mettere un titolo alla tua popup (il secondo parametro della funzione window.open), potrebbe anche dipendere da quello


    tempo fà riscrissi il codice di apertura popup/fullscreen in AS2... ma non ce l'ho appresso, appena posso lo posto, così magari se questo non funziona, provi quello

    [edit] ok, ce l'avevo appresso...

    codice:
    /*----------------------------------------------------------------------------------------------------------------------*
    * javascript method: window.open("strUrl", "strWinName", "strFeatures");						*
    * flash callback method: getURL("javascript:window.open('','','');void(0);");						*
    *															*
    * resume of features --> width:Number, height:Number, left:Number, top:Number, resizable:Boolean, fullscreen:Boolean,	*
    * resume of features --> menubar:Boolean, toolbar:Boolean, location:Boolean, scrollbars:Boolean, status:Boolean		*
    * for the Boolean return, choose string substitute true/"yes", false/"no"						*
    *-----------------------------------------------------------------------------------------------------------------------*/
    // Featured function for JS window.open() method in flash
    // Test passed with: Firefox 1.5.0.6 , Internet Explorer 5/6
    // usage: openPopup("mypage.html", "myName", {width:300, height:200, left:100, top:100, resizable:"no", fullscreen:"no", menubar:"yes", toolbar:"yes", location:"no", scrollbars:"no", status:"no"});
    // function definition:
    var openPopup:Function = function(url:String, winName:String, features:Object):Void {
    	var filtered_features:String = "";
    	if(features != undefined){
    		filtered_features+= "width="+ ((features.width != undefined) ? features.width : System.capabilities.screenResolutionX)+", ";
    		filtered_features+= "height="+ ((features.height != undefined) ? features.height : System.capabilities.screenResolutionY)+", ";
    		filtered_features+= "left="+ ((features.left != undefined) ? features.left : 0)+", ";
    		filtered_features+= "top="+ ((features.top != undefined) ? features.top : 0)+", ";
    		filtered_features+= "resizable="+ ((features.resizable != undefined) ? features.resizable : "no")+", ";
    		filtered_features+= "fullscreen="+ ((features.fullscreen != undefined) ? features.fullscreen : "no")+", ";
    		filtered_features+= "menubar="+ ((features.menubar != undefined) ? features.menubar : "no")+", ";
    		filtered_features+= "toolbar="+ ((features.toolbar != undefined) ? features.toolbar : "no")+", ";
    		filtered_features+= "location="+ ((features.location != undefined) ? features.location : "no")+", ";
    		filtered_features+= "scrollbars="+ ((features.scrollbars != undefined) ? features.scrollbars : "no")+", ";
    		filtered_features+= "status="+ ((features.status != undefined) ? features.status : "no")+", ";
    		getURL("javascript:window.open('"+url+"', '"+winName+"', '"+filtered_features+"');void(0);");
    	}
    }
    //
    questa va solo incollata così com'è sul frame, mentre sul pulsante scrivi
    codice:
    on(release){
    	var centerX = (System.capabilities.screenResolutionX-550)/2;
    	var centerY = (System.capabilities.screenResolutionY-450)/2;
    	openPopup("zuppa.html", "Zuppa", {width:550, height:450, left:centerX, top:centerY, resizable:"no", fullscreen:"no", menubar:"no", toolbar:"no", location:"no", scrollbars:"no", status:"no"});
    }

  4. #4
    grazie
    appena ho tempo provo
    Sei grandeeeeeeee
    http://www.vitoloweb.net

  5. #5
    ma il primo codice l'inserisco nel primo frame del swfcaricato o nel filmato principale?
    perkè nn funziona?
    devo provare on line?
    Sei grandeeeeeeee
    http://www.vitoloweb.net

  6. #6
    Utente di HTML.it L'avatar di and80
    Registrato dal
    Mar 2003
    Messaggi
    15,182
    avevo un esempio on line funzionante, ma mi pare che l'ho tolto, domani lo rimetto e ti posto il link per scaricarlo

  7. #7
    grazie attendo
    Sei grandeeeeeeee
    http://www.vitoloweb.net

  8. #8
    ciao and80,

    mi posti gentilmente il link promesso
    Grazie anticipatamente
    Sei grandeeeeeeee
    http://www.vitoloweb.net

  9. #9

  10. #10
    Utente di HTML.it L'avatar di and80
    Registrato dal
    Mar 2003
    Messaggi
    15,182
    Originariamente inviato da Vitoloweb
    up :quote:
    scusami Vitoloweb... m'ero scordato... spero di ricordarmelo stasera quando torno a casa

    comunque dai, non è difficile... ho scritto un articolo per quel codice, magari dagli uno sguardo, potrebbe bastarti senza il bisogno del file

    http://www.v2online.it/articoli/flash-popup.html

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.