[pmwiki-users] custom markup for personalized <script> tag
Sergio Andreozzi
sergio.andreozzi at cnaf.infn.it
Sat Apr 16 20:47:50 CDT 2005
Hello,
I'd like to be able to insert the following markup type in my wiki pages:
<script
src="http://syndicate.ebay.com/ebayshop/ebayshop.dll?GetSellerList&uid=MYEBAYID&fontsize=2&numofitems=50&highlight=1&fontface=verdana&sortby=endtime&sortdir=asc&siteid=101&catid=0"></script>
where one part is fixed:
<script
src="http://syndicate.ebay.com/ebayshop/ebayshop.dll?PARAMS"></script>
while the PARAMS part depends on the wiki page. This is to be able to
add my ebay advs in my website.
I don't want to use the EnableHTML script
(http://www.pmwiki.org/wiki/Cookbook/EnableHTML) for security reasons. I
think it is safer if I define a customized markup in my config.php like:
Markup("ebay", "inline", "/'ebay(.*?)ebay'/", "<script
src=\"http://syndicate.ebay.com/ebayshop/ebayshop.dll$1\"></script>");
The problem is that if I add in a wiki page the following text:
'ebay?GetSellerList&uid=MYEBAYID&fontsize=2&numofitems=50&highlight=1&fontface=verdana&sortby=endtime&sortdir=asc&siteid=101&catid=0ebay'
this get translated like:
<script src="<a class='urllink'
href='http://syndicate.ebay.com/ebayshop/ebayshop.dll?GetSellerList&uid=MYEBAYID&fontsize=2&numofitems=50&highlight=1&fontface=verdana&sortby=endtime&sortdir=asc&siteid=101&catid=0'
rel='nofollow'>http://syndicate.ebay.com/ebayshop/ebayshop.dll?GetSellerList&uid=MYEBAYID&fontsize=2&numofitems=50&highlight=1&fontface=verdana&sortby=endtime&sortdir=asc&siteid=101&catid=0</a>"></script>
and of course it doesn't work.
There is any way to get a more clean translation, like the one I would
expect:
<script
src=\"http://syndicate.ebay.com/ebayshop/ebayshop.dll?GetSellerList&uid=MYEBAYID&fontsize=2&numofitems=50&highlight=1&fontface=verdana&sortby=endtime&sortdir=asc&siteid=101&catid=0\"></script>
Thanks,
Sergio
More information about the pmwiki-users
mailing list