<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
<br>Ron, that's why asked if the callJS could talk to the DOM directly.<br><br>In the archives I found this posted by Julian:<br><br>I added a new function 'callJS(functionName, parameters)' which wraps<br>Flash's ExternalInterface.call method.<br>Use it like this:<br><pre>callJS('myJavascriptFunctionName', 'parameters');<br> <br></pre>Now, if it is a wrap of the ExternalInterface.call method, which looks like this:<br><br>ExternalInterface.call(”window.location.href.toString”);<br><br>then in your code,<br><br>my_location = callJS('window.location.href.toString');<br><br>*should* give you the URL location of the page the .rlo (or at least the swf engine) is executing from.<br>No need for any extra javascript in the <HEAD>. <br><br>Dave<br><br><br><br><hr id="stopSpelling">From: ronm@mitchellmedia.co.uk<br>To: xerte@lists.nottingham.ac.uk<br>Subject: RE: [Xerte] detect/retrieve url of an LO<br>Date: Sat, 19 Sep 2009 19:03:09 +0100<br><br>
<style>
.ExternalClass .EC_shape
{;}
</style>
<style>
.ExternalClass p.EC_MsoNormal, .ExternalClass li.EC_MsoNormal, .ExternalClass div.EC_MsoNormal
{margin-bottom:.0001pt;font-size:12.0pt;font-family:'Times New Roman','serif';}
.ExternalClass a:link, .ExternalClass span.EC_MsoHyperlink
{color:blue;text-decoration:underline;}
.ExternalClass a:visited, .ExternalClass span.EC_MsoHyperlinkFollowed
{color:purple;text-decoration:underline;}
.ExternalClass p
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:'Times New Roman','serif';}
.ExternalClass p.EC_ecmsonormal, .ExternalClass li.EC_ecmsonormal, .ExternalClass div.EC_ecmsonormal
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:'Times New Roman','serif';}
.ExternalClass p.EC_ecmsochpdefault, .ExternalClass li.EC_ecmsochpdefault, .ExternalClass div.EC_ecmsochpdefault
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:'Times New Roman','serif';}
.ExternalClass p.EC_ecmsonormal1, .ExternalClass li.EC_ecmsonormal1, .ExternalClass div.EC_ecmsonormal1
{margin-right:0cm;margin-bottom:0cm;margin-left:0cm;margin-bottom:.0001pt;font-size:11.0pt;font-family:'Calibri','sans-serif';}
.ExternalClass p.EC_ecmsochpdefault1, .ExternalClass li.EC_ecmsochpdefault1, .ExternalClass div.EC_ecmsochpdefault1
{margin-right:0cm;margin-left:0cm;font-size:10.0pt;font-family:'Times New Roman','serif';}
.ExternalClass span.EC_ecmsohyperlink
{;}
.ExternalClass span.EC_ecmsohyperlinkfollowed
{;}
.ExternalClass span.EC_ecemailstyle17
{;}
.ExternalClass span.EC_ecemailstyle18
{;}
.ExternalClass span.EC_ecemailstyle19
{;}
.ExternalClass span.EC_ecemailstyle20
{;}
.ExternalClass span.EC_ecmsohyperlink1
{color:blue;text-decoration:underline;}
.ExternalClass span.EC_ecmsohyperlinkfollowed1
{color:purple;text-decoration:underline;}
.ExternalClass span.EC_ecemailstyle171
{font-family:'Calibri','sans-serif';color:windowtext;}
.ExternalClass span.EC_ecemailstyle181
{font-family:'Calibri','sans-serif';color:#1F497D;font-weight:normal;font-style:normal;text-decoration:none none;}
.ExternalClass span.EC_ecemailstyle191
{font-family:'Calibri','sans-serif';color:#1F497D;}
.ExternalClass span.EC_ecemailstyle201
{font-family:'Calibri','sans-serif';color:#1F497D;font-weight:normal;font-style:normal;text-decoration:none none;}
.ExternalClass span.EC_EmailStyle34
{font-family:'Calibri','sans-serif';color:#1F497D;}
.ExternalClass span.EC_EmailStyle35
{font-family:'Calibri','sans-serif';color:#1F497D;}
.ExternalClass span.EC_EmailStyle36
{font-family:'Calibri','sans-serif';color:#1F497D;}
.ExternalClass .EC_MsoChpDefault
{font-size:10.0pt;}
@page Section1
{size:612.0pt 792.0pt;}
.ExternalClass div.EC_Section1
{page:Section1;}
</style>
<div class="EC_Section1">
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">Hi Julian</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">As we discussed I really wanted this to work without the need for
any additional javascript so that it could be used via any toolkits
installation so if there is a function in the existing code somewhere please
let me know. As we briefly discussed it would be really good if there was a way
of containing all the code in the models and have those automatically detected
and displayed as page types available. It would make updating and keeping
custom pages in sync much easier.</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">I’ve created a simple example of each of the four custom
page types I’ve adapted and integrated and made them available as a zip
too at <a href="http://mitchellmedia.co.uk/?p=230">http://mitchellmedia.co.uk/?p=230</a>
</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">Cheers</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">Ron</span></p>
<p class="EC_MsoNormal"><a name="_MailEndCompose"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></a></p>
<div>
<div style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US"> xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>RonM<br>
<b>Sent:</b> 18 September 2009 09:52<br>
<b>To:</b> 'Xerte discussion list'<br>
<b>Subject:</b> RE: [Xerte] detect/retrieve url of an LO</span></p>
</div>
</div>
<p class="EC_MsoNormal"> </p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">Yes indeed! ....?</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></p>
<div>
<div style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US"> xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>Julian Tenney<br>
<b>Sent:</b> 18 September 2009 09:28<br>
<b>To:</b> Xerte discussion list<br>
<b>Subject:</b> RE: [Xerte] detect/retrieve url of an LO</span></p>
</div>
</div>
<p class="EC_MsoNormal"> </p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);">I think what you want is the server.com/toolkits/play_123,
right?</span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></p>
<p class="EC_MsoNormal"><span style="font-size: 11pt; font-family: 'Calibri','sans-serif'; color: rgb(31, 73, 125);"> </span></p>
<div>
<div style="border-style: solid none none; border-color: rgb(181, 196, 223) -moz-use-text-color -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal" style="margin-left: 36pt;"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';" lang="EN-US">
xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>Dave Burnett<br>
<b>Sent:</b> Friday, September 18, 2009 12:20 AM<br>
<b>To:</b> Xerte list<br>
<b>Subject:</b> RE: [Xerte] detect/retrieve url of an LO</span></p>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"> </p>
<p class="EC_MsoNormal" style="margin-right: 0cm; margin-bottom: 12pt; margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"><br>
Can you talk to the DOM directly with callJS?<br>
Maybe just window.location?</span></p>
<div style="margin-left: 36pt;">
<div class="EC_MsoNormal" style="text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">
<hr size="2" width="100%" align="center">
</span></div>
</div>
<p class="EC_MsoNormal" style="margin-right: 0cm; margin-bottom: 12pt; margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Subject:
RE: [Xerte] detect/retrieve url of an LO<br>
Date: Thu, 17 Sep 2009 15:40:36 -0700<br>
From: Paul.Swanson@harlandfs.com<br>
To: xerte@lists.nottingham.ac.uk</span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">You might try a javascript
function in the launching web page:</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">function returnURL() {</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> var
baseURL = document.URL;</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> return
baseURL;</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">}</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">Then use Xerte’s
callJS() method to get it.</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<div style="border-style: none none none solid; border-color: -moz-use-text-color -moz-use-text-color -moz-use-text-color blue; border-width: medium medium medium 1.5pt; padding: 0cm 0cm 0cm 4pt;">
<div>
<div style="border-style: solid none none; border-color: -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal" style="margin-left: 36pt;"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';"> xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>RonM<br>
<b>Sent:</b> Thursday, September 17, 2009 3:29 PM<br>
<b>To:</b> 'Xerte discussion list'<br>
<b>Subject:</b> RE: [Xerte] detect/retrieve url of an LO</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"> </span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">Thanks for the suggestion but
that doesn’t work for what I want. _url comes close but this may be a
question for Pat as what I really want is to automatically detect, or at least
dynamically create, the public url of the LO. Hopefully Pat will have a
suggestion tomorrow.</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<div>
<div style="border-style: solid none none; border-color: -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal" style="margin-left: 36pt;"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';"> xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>Paul Swanson<br>
<b>Sent:</b> 17 September 2009 22:53<br>
<b>To:</b> Xerte discussion list<br>
<b>Subject:</b> RE: [Xerte] detect/retrieve url of an LO</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"> </span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);">FileLocation?</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: rgb(31, 73, 125);"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
<div style="border-style: none none none solid; border-color: -moz-use-text-color -moz-use-text-color -moz-use-text-color blue; border-width: medium medium medium 1.5pt; padding: 0cm 0cm 0cm 4pt;">
<div>
<div style="border-style: solid none none; border-color: -moz-use-text-color; border-width: 1pt medium medium; padding: 3pt 0cm 0cm;">
<p class="EC_MsoNormal" style="margin-left: 36pt;"><b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';">From:</span></b><span style="font-size: 10pt; font-family: 'Tahoma','sans-serif';"> xerte-bounces@lists.nottingham.ac.uk
[mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>RonM<br>
<b>Sent:</b> Thursday, September 17, 2009 2:50 PM<br>
<b>To:</b> 'Xerte discussion list'<br>
<b>Subject:</b> [Xerte] detect/retrieve url of an LO</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"></span></p>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"> </span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Hi Pat/Julian</span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">I should probably know this but is there a
system variable or functions or something which automatically contains the url
of the LO? </span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Cheers</span></p>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Ron</span></p>
</div>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"> </span></p>
<div style="margin-left: 36pt;">
<div class="EC_MsoNormal" style="text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">
<hr size="2" width="100%" align="center">
</span></div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Hotmail: Powerful Free email with security
by Microsoft. <a href="http://clk.atdmt.com/GBL/go/171222986/direct/01/">Get it now.</a></span></p>
</div><br /><hr />Bing brings you health info from trusted sources. <a href='http://www.bing.com/search?q=pet+allergy&form=MHEINA&publ=WLHMTAG&crea=TXT_MHEINA_Health_Health_PetAllergy_1x1' target='_new'>Try it now!</a></body>
</html>