[pmwiki-users] should enabling html also enable js?
    Patrick R. Michaud 
    pmichaud at pobox.com
       
    Tue Jul 31 17:46:12 CDT 2007
    
    
  
On Mon, Jul 30, 2007 at 11:48:17AM -0500, Tegan Dowling wrote:
> In local/ I have a file GroupName.PageName.php which contains
> 
> <?php if (!defined('PmWiki')) exit();
> 
> 	// Enable HTML
> 		include_once('cookbook/enablehtml.php');
> 		EnableHtml('a|script');
> 
> On the page itself, I have the following (except with a real event ID number):
> 
> <script type="text/javascript">
> 	eventbrite_event = "EventIDHere";
> 	eventbrite_view = "full";
> 	eventbrite_width = "80%";
> 	eventbrite_height = "1500";
> </script>
> <script type="text/javascript" src="http://www.eventbrite.com/js/events.js">
> </script>
I suspect the problem is that EnableHTML simply preserves the tags --
it doesn't preserve things in the middle of the tags.  So, in the first
<script> tag above the variable initializations end up being wrapped in
<pre>..</pre> tags.  The second one should've worked, however.
Still, I'd probably write the above as
    <script type="text/javascript">[=
	eventbrite_event = "EventIDHere";
 	eventbrite_view = "full";
 	eventbrite_width = "80%";
 	eventbrite_height = "1500";
    =]</script>
    <script type="text/javascript" src="http://www.eventbrite.com/js/events.js"></script>
so that PmWiki isn't tempted to put its own block markups in 
the middle of the text.
If that doesn't help, I'll see about setting up an example page
on pmwiki.org to see if we can troubleshoot this.
Pm
    
    
More information about the pmwiki-users
mailing list