Re: [OT] Anti-Spam solution for web pages.
Re: [OT] Anti-Spam solution for web pages.
- Subject: Re: [OT] Anti-Spam solution for web pages.
- From: Jon Pugh <email@hidden>
- Date: Fri, 17 Oct 2003 11:35:30 -0700
At 7:19 AM -0400 10/17/03, Gary Lists wrote:
>
> Now make it a script that operates on the selection in BBEdit. ;)
>
>
I'm pretty sure I have an AS that does that (downloaded.) I'll check the
>
folder, Jon.
I modified Rachel's script to this:
tell application "BBEdit"
set newStr to ""
set selectedText to contents of selection
if selectedText as string is "" then
activate
display dialog "Please select some text in BBEdit"
else
set contents of selection to my parseString(selectedText)
end if
end tell
on parseString(oldStr)
set newStr to ""
repeat with aChr in characters of oldStr
set thisNum to ASCII number of aChr
set newStr to newStr & "&#" & thisNum & ";"
end repeat
return newStr
end parseString
Now I can use the parseString routine in other scripts, notably my Netter's Dinner RSVP page script which puts email addresses on a page. These days a lot of people don't want their email addresses posted, so this should provide some benefit.
Thanks.
Jon
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.