• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Safari — get selected text in text area
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Safari — get selected text in text area


  • Subject: Safari — get selected text in text area
  • From: Jeremy K Sellors <email@hidden>
  • Date: Sat, 30 Apr 2005 12:36:52 -0700

Hi'
How do you set a variable to the selected text in a web content management system (CMS) page text entry area.
--<a href="http://www.canfor.com/">here…</a>
set Link to the clipboard
tell application "Safari"
tell front document
set LinkedText to get the selected
end tell
end tell
set WebLink to "<a href=\"" & Link & "\">" & LinkedText & "</a>"
set the clipboard to WebLink

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Safari — get selected text in text area
      • From: Jeremy K Sellors <email@hidden>
  • Prev by Date: Re: Using AppleScript to Detect Nul Characters
  • Next by Date: Re: theText is empty. why?
  • Previous by thread: Re: theText is empty. why?
  • Next by thread: Re: Safari — get selected text in text area
  • Index(es):
    • Date
    • Thread