design at softflow.co.uk
Wed Nov 16 09:07:06 CST 2005
will enable easy change of font sizes. To use pmwiki's capabilities for
internationalisations I would like to use some php(pmwiki) variables
inside the script. I know I could achieve this by using the
$HTMLHeaderFmt variable and load the script via this. But this will
bloat the html code for each page. My workaround at the moment is to
use $HTMLHeaderFmt and load the parts of the script with the
remaining script with <script ... src=..... ></script>.
This way I got less script code in the html source, but I wonder if
there is a good way to avoid it altogether.
To illustrate, here is the php code I use at the moment, with the
$HTMLHeaderFmt = "
var bigger = new Array(11);
bigger = '<p>\$[Text Size]:<br/>';
bigger = ' \$[larger] ';
bigger = '\$[increase text size]';
bigger = ' | ';
var reset = new Array(11);
reset = '';
reset = ' \$[default] ';
reset = '\$[reset text to default]';
reset = ' | ';
var smaller = new Array(10);
smaller = ' \$[smaller] ';
smaller = '\$[decrease text size]';
smaller = '</p>';
But all this will show in the html page source.
More information about the pmwiki-users