1. in the the header.php of your theme in wordpress or in your static page
<head>
<script type="text/javascript"
src="<?php echo bloginfo('template_url'); ?>/js/PopUpWin.js">
</script>
</head>
2. creation a folder “js” with a file “PopUpWin.js” in your wordpress theme or in your site:
inside:
function PopUp(theURL,winName,features, myWidth, myHeight, isCenter) { //v3.0
if(window.screen)if(isCenter)if(isCenter=="true"){
var myLeft = (screen.width-myWidth)/2;
var myTop = (screen.height-myHeight)/2;
features+=(features!='')?',':'';
features+=',left='+myLeft+',top='+myTop;
}
window.open(theURL,winName,features+((features!='')?',':'')
+'width='+myWidth+',height='+myHeight);
}
3. creation a button1.swf call button1.fla with flash or called what you want
in actionscript
on(release){
getURL("javascript:PopUp('http://www.yoursite.com/youranimationswf.swf',
'popup','scrollbars=no','766','600','true')");
// open popup }
4. go and play your button.swf anywhere in your wordpress site or static page
Download fla,swf,readme txt,js folder button.rar
example:
example2: avec lightwindow pour wordpress
http://wordpress.org/extend/plugins/lightwindow-20-for-images/
plugin wordpress
http://mockersubat.fr/plugins/
j’utilise ce plugin
http://www.stickmanlabs.com/lightwindow/
site de l’auteur pour son fonctionnement et les exemples
compatible fancybox et lightbox
exemple pour un swf : ligne de code à inclure dans vos articles ou vos pages :
<a href="gallery/header.swf?You-could-put-a-GET-string-here-for-your-flashvars"
class="lightwindow"
params="lightwindow_width=800,lightwindow_height=345"
title="Preview: Doesn't your masthead look perdy?" >Link Name</a>
Media Movies, Flash, PDF’s… just link directly to the file!
Quicktime Movie Example – 20MB Local File!
Quicktime Movie Example – 5MB Local File!
Apple.com Trailer – Transformers, more than meets the eye!
Single SWF Example – Because I Love Flash…
SWF Gallery – Any media can now be used in a GALLERY! Header #2 Header #3
Flash Paper – The RIGHT way to embed a PDF!
You Tube – 300 Preview
External Sources Look Ma! It’s like a popup window! (Other Domains)
Images Singles or Gallery Sets!
ciao
Pas de commentaires
Laisser une réponse
Vous devez être connecté pour publier un commentaire.