[pmwiki-users] Conditionnal include on ?action

Nicolas Poulain nico.poulain at gmail.com
Wed Oct 31 11:16:53 CDT 2007


Patrick R. Michaud a écrit :
> On Wed, Oct 31, 2007 at 04:55:59PM +0100, Nicolas Poulain wrote:
>> Hi list,
>>
>> The two recipes mimetex or jsMath work very well on my site but i'd like 
>> to make them work together :
>> - While reading pages i'd rather use mimetex to show math contents
>> - while ?action=print it would be better that jsMath does the job
>>
>> I guess there is a way with conditionnal include in local/config but i
>> don't find how to write it.
> 
>   if ($action == 'print') { include_once('cookbook/jsMath.php'); }
>   else { include_once('cookbook/mimetex.php'); }

Yes, $action looks better than $GLOBALS["action"]

Thank you !
--
Nicolas Poulain
http://exomatik.net





More information about the pmwiki-users mailing list