[pmwiki-users] Embed Sporcle
Hans
design5 at softflow.co.uk
Tue Mar 15 06:14:48 CDT 2011
Sunday, March 13, 2011, 7:51:11 AM, Mark Trumpold wrote:
> Does anyone know how I can change this code to embed this sporcle game on my website
> <iframe frameborder="0" scrolling="no" marginheight="0"
> marginwidth="0" id="spFrame"
> src="http://www.sporcle.com/framed/?gid=38ae49c090c&pid=0cbc0c029d4bc453d24975f38c84dc18"
> width="860"></iframe><script type="text/javascript">function
> rIF(ht){document.getElementById("spFrame").height=parseInt(ht)+40;}</script>
you could create a custom markup and put a directive for that into
the page. Something like this:
in config:
$SporcleFmt = '
<iframe frameborder="0" scrolling="no" marginheight="0" marginwidth="0" id="spFrame" src="http://www.sporcle.com/framed/?gid=38ae49c090c&pid=0cbc0c029d4bc453d24975f38c84dc18" width="860"></iframe>
<script type="text/javascript">function rIF(ht){document.getElementById("spFrame").height=parseInt(ht)+40;}</script>
';
Markup('sporcle', 'directives' '/\\(:sporcle:\\)/e',
"Keep($SporcleFmt)";
in a wiki page:
(:sporcle:)
cheers
~Hans
More information about the pmwiki-users
mailing list