• 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
How to script URL Access to post radio buttons?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to script URL Access to post radio buttons?


  • Subject: How to script URL Access to post radio buttons?
  • From: Charles Arthur <email@hidden>
  • Date: Tue, 17 Apr 2001 18:06:50 +0100

So here I am trying to script a search of a site
(http://www.ananova.com/search/index.html) using the word "climber" and
searching within the site. (Which is picked by a radio button below the
emtpy area for the search string.

It seems straightforward enough.. at first:

tell application "URL Access Scripting"
download "http://www.ananova.com/search/index.html"; to thefile form data
"QUERY00=climber" replacing yes with progress --all on a single line
-- this arrives with file type "TEXT" creator type "MSIE"
end tell

However this always does a Web search. I want a site search.

The relevant HTML from the site is:
----
<table>
<form method="post" action="http://www.ananova.com/search/index.html";
name="form">
<tr><td><small><input name="QUERY00" value=""
size="40">&nbsp;&nbsp;</small></td>
<td rowspan="2" valign="top"><input type="image" src="" width="58"
height="22" name="CMD=search.run" alt="Search" border="0"></td></tr>
<tr><td align="left"><small><input type="radio" name="SAVEDB"
value="web">web <input type="radio" name="SAVEDB" value="ananova"
checked>Ananova</small></td></tr></table>
<input name="THRESHOLD" value="60" type="hidden"><input type="hidden"
name="B" value=""><input type="hidden" name="nav_src"
value="LeftColSearchUsed"><input name="ORGANISE_CODED" value="R:date"
type="hidden"><input name="DAYSMINUS" value="30" type="hidden"></form>
<form method="post" action="/search/index.html" name="form">
---

From gazing at this (and earlier failures) I realised that I needed the
"QUERY00=" string. However, I can't work out what to put in the "form data"
string to tell it that which radio button should be checked.
I've tried "{QUERY00=climber,SAVEDB=ananova}" - no dice. It puts
"climber,SAVEDB=ananova} in the search area and searches the Web.
I've tried {"QUERY00=climber,SAVEDB=ananova"}. Won't compile. form data is
a string.

So now I'm trying you guys. Any ideas?

Charles

----------------------------
http://www.ukclimbing.com : 1000+ British crags, 350+ British climbing
walls - searchable by distance and anything else you care to think of -
with weather forecasts for every one, plus maps, articles, news and
features. Plus Britain's busiest climbing discussion boards. And there's
even a cool shop attached.


  • Follow-Ups:
    • Re: How to script URL Access to post radio buttons?
      • From: "M.S.R.F. Schonewille" <email@hidden>
  • Prev by Date: Re: Naming Quark boxes - screwed up!
  • Next by Date: getting a URL from IE
  • Previous by thread: Re: zapping gremlins
  • Next by thread: Re: How to script URL Access to post radio buttons?
  • Index(es):
    • Date
    • Thread