<div dir="ltr">Hello pmwiki users,<br><br>I'm upgrading the wonderful Petko's recipe (thumblist) from v1 to the last one (20081015).<br>I see no problem (I'm playing with the basicer fonctions) but at that time I can't or don't know how to make the lightbox work by default (It did with former thumblist v1).<br>
If I write rel=lightbox, it's working, the lightbox is there, but no way to to make it work by defaut (for thumb and for thumblist, I want both).<br>
<br>---the doc--- :<br>To enable Lightbox for all thumblist galleries by default, set in config.php:<br> $ThumbList['LinkRel'] = 'lightbox';<br><br>---my config (lightbox)--- :<br><br>##-- THUMBLIST ****************************************************************************************<br>
include_once("$FarmD/cookbook/thumblist2.php");<br>##-- LIGHTBOX *******************************************************************************************<br>$ThumbList['fPreChecks'] = 'uThumbLightbox';<br>
function uThumbLightbox(&$opt)<br>{<br> global $HTMLHeaderFmt;<br> if(preg_match("/lightbox/i", @$opt['rel']))<br> {<br> $LightboxDirUrl = "/pub/lb"; # LIGHTBOX DIRECTORY<br> $opt['rel'] = 'lightbox[?G]';<br>
$HTMLHeaderFmt['lightbox'] =<<<EOF<br><script type="text/javascript" src="$LightboxDirUrl/prototype.js"></script><br><script type="text/javascript" src="$LightboxDirUrl/scriptaculous.js?load=effects"></script><br>
<script type="text/javascript"><!--<br>LightboxDirUrl = "$LightboxDirUrl";//--></script><br><script type="text/javascript" src="$LightboxDirUrl/lightbox.js"></script><br>
<link rel="stylesheet" href="$LightboxDirUrl/lightbox.css" type="text/css" media="screen"/><br>EOF;<br> }<br>}<br>$ThumbList['LinkRel'] = 'lightbox';<br> <br>
<br>Any idea of what's wrong ? <br>Looking at the html code there is something strange in the image link :<br><br>When using (notworking) config param I got :<br><pre id="line8"><span class="attribute-name">rel</span>=<span class="attribute-value">"lightbox"</span></pre>
When using (working) rel=lightbox in wiki code I got :<br><pre id="line252"><span class="attribute-name">rel</span>=<span class="attribute-value">"lightbox[1]"</span></pre><br>You can see in live my page I'm playing with this recipe if needed :<br>
<a href="http://www.languefrancaise.net/docs/Argot/Apaches">http://www.languefrancaise.net/docs/Argot/Apaches</a><br>edit password : editer<br><br>Thank you !<br>Gilles.<br><br>---------------------------------------<br>| A | de la langue française<br>
| B | <a href="http://www.languefrancaise.net/" target="_blank">http://www.languefrancaise.net/</a><br>| C | <a href="mailto:languefrancaise@gmail.com" target="_blank">languefrancaise@gmail.com</a><br>
---------------------------------------<br>
</div>