<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>
<br><br>I tried a whole whack of variations and could not come up with a combination to get it to work. :-/<br>The docs at the authors homepage had no sample code snippets, and the example .fla code of course would not transfer.<br><br>The OP never did say how he resolved, so I just dropped it.<br><br><br><hr id="stopSpelling">Subject: RE: [Xerte] how to strip out a specific string?<br>Date: Fri, 17 Apr 2009 12:19:10 +0100<br>From: Julian.Tenney@nottingham.ac.uk<br>To: xerte@lists.nottingham.ac.uk<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 span.EC_ecapple-style-span
{;}
.ExternalClass span.EC_ecapple-converted-space
{;}
.ExternalClass span.EC_EmailStyle20
{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);">In Xerte the replace method is added to the String class, so it’s</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);">myString.replace(myRegExp, ‘replaceString’);</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> Monday, April 13, 2009 2:17 AM<br>
<b>To:</b> Xerte list<br>
<b>Subject:</b> RE: [Xerte] how to strip out a specific string?</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>
<br>
I could be imagining things, but I thought Julian just posted something about
Regular Expressions now being supported.<br>
<br>
If that is true, then this would work:<br>
<br>
new_xml = replace(original_xml, /the_string_here/g, "");<br>
<br>
the /g at the end if the string parameter means "global", so it would
replace all the instances of that URL with "".<br>
<br>
Dave<br>
<br>
</span></p>
<div class="EC_MsoNormal" style="margin-left: 36pt; text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">
<hr id="EC_stopSpelling" size="2" width="100%" align="center">
</span></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';">From:
ronm@mitchellmedia.co.uk<br>
To: xerte@lists.nottingham.ac.uk<br>
Subject: Re: [Xerte] how to strip out a specific string?<br>
Date: Sun, 12 Apr 2009 20:19:55 +0100</span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Cheers Dave that's very helpful - I'll give
that a try.</span></p>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><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';">On 12 Apr 2009, at 19:35, Dave Burnett
wrote:</span></p>
</div>
<blockquote style="margin-bottom: 5pt;">
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';"> </span></p>
<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'; color: black;"><br>
It actually does have a closing tag: /><br>
<br>
XML shorthands the closing tag to save characters when all the info is
contained in the attributes, i.e. there is no actual value between the tags.<br>
<br>
</span><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"><name>jamesclay (James Clay)</name> //no attributes,
data between tags<br>
<br>
<br>
<link type="text/html" rel="alternate" href="<a href="http://twitter.com/jamesclay/statuses/1483252089">http://twitter.com/jamesclay/statuses/1483252089</a>"/><br>
<br>
//all data in opening tag attributes, no explicit closing tag, just /><br>
<br>
</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"><br>
So if you know the format you show below would be consistent, you could key on
that "/>" as the end of the string and RFind (reverse find) back
to the first "/" you hit.<br>
<br>
That should isolate the actual picture name/format.<br>
<br>
Dave<br>
<br>
</span></p>
<div class="EC_MsoNormal" style="margin-left: 36pt; text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;">
<hr id="EC_EC_stopSpelling" size="2" width="100%" align="center">
</span></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'; color: black;">From:<span class="EC_ecapple-converted-space"> </span><a href="mailto:ronm@mitchellmedia.co.uk">ronm@mitchellmedia.co.uk</a><br>
To:<span class="EC_ecapple-converted-space"> </span><a href="mailto:xerte@lists.nottingham.ac.uk">xerte@lists.nottingham.ac.uk</a><br>
Date: Sun, 12 Apr 2009 19:22:22 +0100<br>
Subject: [Xerte] how to strip out a specific string?</span></p>
<div>
<div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">Hi all</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">I've been experimenting with the
new module method of creating templates and have created a couple of new
templates optimised for a specific purpose which I’ll happily share with the
community once complete. One is an optimised view of twitter feeds but
unless I’m mistaken it seems like the xml isn't complete for some reason. I can
pick up and display the text and links etc ok but I can't work out how to
access the profile pics. Here's an example entry...</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"><entry></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> <id>tag:search.twitter.com,2005:1483252089</id></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<published>2009-04-09T12:59:26Z</published></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> <link
type="text/html" rel="alternate" href="<a href="http://twitter.com/jamesclay/statuses/1483252089">http://twitter.com/jamesclay/statuses/1483252089</a>"/></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<title>@ronm123 I meant in a browser, via a second projector
probably.</title></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> <content
type="html">&lt;a href="<a href="http://twitter.com/ronm123">http://twitter.com/ronm123</a>"&gt;@ronm123&lt;/a&gt;
I meant in a browser, via a second projector probably.</content></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<updated>2009-04-09T12:59:26Z</updated></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> <link
type="image/png" rel="image" href="<a href="http://s3.amazonaws.com/twitter_production/profile_images/96243182/Photo14_normal.jpg">http://s3.amazonaws.com/twitter_production/profile_images/96243182/Photo14_normal.jpg</a>"/></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<twitter:source>&lt;a href="<a href="http://twitter.com/">http://twitter.com/</a>"&gt;web&lt;/a&gt;</twitter:source></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> <author></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<name>jamesclay (James Clay)</name></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
<uri><a href="http://twitter.com/jamesclay%3C/uri">http://twitter.com/jamesclay</uri</a>></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">
</author></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> </entry></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">I want to be able to strip out
the path to the .jpg e.g.<a href="http://s3.amazonaws.com/twitter_production/profile_images/96243182/Photo14_normal.jpg">http://s3.amazonaws.com/twitter_production/profile_images/96243182/Photo14_normal.jpg</a></span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">But can't work out how to do
that. I can access the content of <id>,<title> and even
<name> but the tag containing the profile pic link e.g. <link
type=”image/png” doesn’t have a closing tag. Presumably I need some kind of
function + regular expression - any suggestions?</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;"> </span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">Cheers</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
<div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 11pt; font-family: 'Arial','sans-serif'; color: black;">Ron</span><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"></span></p>
</div>
</div>
</div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;"> </span></p>
<div class="EC_MsoNormal" style="margin-left: 36pt; text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;">
<hr size="2" width="100%" align="center">
</span></div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif'; color: black;">Rediscover Hotmail®: Get e-mail
storage that grows with you.<span class="EC_ecapple-converted-space"> </span><a href="http://windowslive.com/RediscoverHotmail?ocid=TXT_TAGLM_WL_HM_Rediscover_Storage1_042009">Check
it out.</a>_______________________________________________<br>
Xerte mailing list<br>
<a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><br>
<a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a></span></p>
</div>
</blockquote>
</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';"> </span></p>
<div class="EC_MsoNormal" style="margin-left: 36pt; text-align: center;" align="center"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">
<hr size="2" width="100%" align="center">
</span></div>
<p class="EC_MsoNormal" style="margin-left: 36pt;"><span style="font-size: 10pt; font-family: 'Verdana','sans-serif';">Rediscover Hotmail®: Now available on your
iPhone or BlackBerry <a href="http://windowslive.com/RediscoverHotmail?ocid=TXT_TAGLM_WL_HM_Rediscover_Mobile1_042009">Check it out.</a></span></p>
</div><br /><hr />Windows Live™: Keep your life in sync. <a href='http://windowslive.com/explore?ocid=TXT_TAGLM_WL_allup_1a_explore_042009' target='_new'>Check it out.</a></body>
</html>