Re: [xwiki-users] JavaScript image manipulation

2008-05-11 Thread Mike Oliver

\]Ok I found the \['example'\] but that leaves the  AEBtn_0.jpb 
I am trying to manipulate some image files using JavaScript.

But when I insert a tag as follows the javascript []'s get interpretted as a
wiki link, 

lt;a href=/Sandbox/WebHome
onMousedown=document.images['example'].src=img2.src
onMouseup=document.images['example'].src=img1.srcgt;
lt;mg src={image:AEBtn_0.jpg} name=example border=0gt;lt;/agt;



-- 
View this message in context: 
http://www.nabble.com/JavaScript-image-manipulation-tp17177802p17179133.html
Sent from the XWiki- Users mailing list archive at Nabble.com.

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] JavaScript image manipulation

2008-05-11 Thread Guillaume Lerouge
Hi Mike,

\]Ok I found the \['example'\] but that leaves the  AEBtn_0.jpb
 I am trying to manipulate some image files using JavaScript.

 But when I insert a tag as follows the javascript []'s get interpretted as
 a
 wiki link,

 lt;a href=/Sandbox/WebHome
 onMousedown=document.images['example'].src=img2.src
 onMouseup=document.images['example'].src=img1.srcgt;
 lt;mg src={image:AEBtn_0.jpg} name=example border=0gt;lt;/agt;


To prevent the wiki syntax from being interpreted in javascript code you
should use the {pre} tag :

{pre}
code type=javascript
some javascript code here
/code
{/pre}

It's the only exception : though it is a {} tag it needs to be closed with
{/} (while {table} is closed {table} for instance).

Guillaume
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users