Cacher Fil RSS

Démonstration

Voici la liste de widget possédant une démo. Certaine démo ne fonctionnent pas sur ce serveur, c’est normal ! Elles utilisent des données externes (comme une base de données ou un annuaire LDAP) non disponnible sur ce serveur.

 

Pxxo_Widget_Javascript

Apparence(s)

Exemple 1
Tooltips | Window | Dialog

Usage

<?php

require_once 'Pxxo/Widget.php';
require_once 
'Pxxo/Widget/Javascript/Window.php';



class 
t1 extends Pxxo_Widget
{
  function 
t1($params = array()) { t1::__construct($params); }
  function 
__construct($params = array()) { 
      
parent::__construct($params__FILE__); 
      
$this->addDecorator(new Pxxo_Widget_Javascript_Prototype(array('version'=>'1.5.1''modules'=>array('effects'))));
      
$this->addDecorator('Pxxo_Widget_Javascript_Window');
  }
  function 
defaut() { 
      
$html = <<<EOT
<span id="id1">Tooltips</span> | <a href="#" id="id2">Window</a> | <a href="#" id="id3">Dialog</a> 
<script type="text/javascript">

// Tooltip
TooltipManager.init("tooltip", 
{}{showEffect: Element.show, hideEffect: Element.hide}); 
TooltipManager.addURL("id1", "http://www.pxxo.net", 500, 200);

// Window
var win = new Window('winid', 
{className: "alphacube", title: "Pxxo", top:70, left:100, width:300, height:200, url: "http://www.pxxo.net/", showEffectOptions: {duration:1.5}});
Event.observe('id2', 'click', function() 
{ win.show();  });

// Dialog
Event.observe('id3', 'click', function() 
{ 
Dialog.alert("PXXO", 
{className: "alphacube",width:300, height:100, okLabel: "close", ok:function(win) {alert("bye !"); return true;}});
});

</script>
EOT;
      
$this->setTemplateRaw($this->getMode(), $html); 
  }
}
$obj1 = new t1();


?>

 

 

 

Powered by Pxxo Valid XHTML 1.1