Mark Lee writes:
site is at Wikidot, and one of the things I did there is shown below: http://picturecollection.wikidot.com/test3:23 If you click on the picture, the click location is captured behind the scenes, then X and Y coordinates are displayed in a couple text boxes.

Here is the code I used in Wikidot. Can this be done in PMWiki?

Yes, it can.

Create a form with the required form fields, see http://www.pmwiki.org/wiki/PmWiki/Forms .

Create a custom markup for the <canvas> element, see http://www.pmwiki.org/wiki/PmWiki/CustomMarkup or start with an existing recipe like one of the Flash, Video or Java applet recipes and change it to produce your canvas HTML.

To insert stuff in the HTML <head>...</head> section, add the stuff as an element to the $HTMLHeaderFmt, something like:


$HTMHHeaderFmt['my-recipe'] = <<<EOF
<script type="text/javascript">
// your javascript here
</script>
EOF;

-or-

$HTMHHeaderFmt['my-recipe'] = '<script type="text/javascript" src="$PubDirUrl/your-script.js"></script>';

where $PubDirUrl is normally the url address of your pub/ directory (and PmWiki guesses it in most cases.

Petko

_______________________________________________
pmwiki-users mailing list
[email protected]
http://www.pmichaud.com/mailman/listinfo/pmwiki-users

Reply via email to