Mercurial > hg > digilib-old
view client/digitallibrary/jquery/jquery-test-full.html @ 760:f0be4432f515 jquery
primitive plugin extension mechanism - unsure how useful this is
author | hertzhaft |
---|---|
date | Tue, 08 Feb 2011 23:57:39 +0100 |
parents | 4c0cc97a6399 |
children | aab01da232ef |
line wrap: on
line source
<?xml version="1.0" ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Digilib jQuery Test: fullscreen</title> <style type="text/css"> body { background: silver; } #debug { background-color: beige; position: absolute; opacity: 50%; top: 4px; left: 300px; width: 500px; padding: 0px 5px; font-family: Arial; font-size: 9px; } </style> <script type="text/javascript" src="jquery-1.4.4.js"></script> <script type="text/javascript" src="dlGeometry.js"></script> <script type="text/javascript" src="jquery.cookie.js"></script> <script type="text/javascript" src="jquery.digilib.js"></script> <link rel="stylesheet" type="text/css" href="jquery.digilib.css" /> <script type="text/javascript"> $(document).ready(function(){ var opts = { interactionMode : 'fullscreen', scalerBaseUrl : 'http://digilib.biblhertz.it/digilib04/servlet/Scaler' }; var $div = $('div.digilib'); $div.digilib(opts); var obj = { 'initExtension' : function() { var settings = $(this).data('digilib').settings; console.debug('initExtension:', this, 'settings:', settings); }, 'options' : { 'test' : 'content of option "test"' }, }; $div.digilib('extendPlugin', obj); $div.digilib('initExtension'); }); </script> </head> <body> <div id="digilib-1" class="digilib"> <img src="http://digilib.biblhertz.it/digilib04/servlet/Scaler?dw=200&dh=200&fn=/digisprint/jquery/FransHals-WillemVanHeythuysen" /> </div> <div id="debug">DEBUG</div> </body> </html>