I personally like Awk in place of, or in addition to, Grep. Examine the code 
for the webpage and see if there is always some element or bit of text that 
appears just before the informaiton you want, then use Grep or Awk to get at 
that area. You might then parse further in the shell, or just use Applescript 
to strip away unnecessary information.
On Jun 14, 2013, at 2:44 PM, Traci <our4p...@gmail.com> wrote:

> I haven't checked out those pages.  I found a manual online which listed a 
> bunch of definitions with curl.  No luck yet with grep.
> 
> Oops, no the webpage I pasted was the radio station's page.  On that page, 
> inside a frame, it always says what is currently playing.  That is the piece 
> of text I'd like to grab.
> 
> I'll check out your second suggestion, thanks.
> 
> Traci
> On Jun 14, 2013, at 11:18 AM, Chris Blouch <cblo...@aol.com> wrote:
> 
>> Not to overstate the obvious but have you checked the man pages for curl and 
>> grep? You might also want to check out the macport version of wget. What are 
>> you trying to scrape from the page you listed? I didn't notice the 
>> temperature on there.
>> 
>> CB
>> 
>> On 6/14/13 2:10 PM, Traci wrote:
>>> Hi all,
>>> 
>>> Can anyone point me in the correct direction to learn more about curl 
>>> commands and grep?  I've been googling, but I'm not getting very far.
>>> 
>>> I have the weather temp script, where I can now hit a keyboard shortcut and 
>>> the current temp is read out for me.
>>> 
>>> I'd like to create a similar script for a local radio station's now playing 
>>> website.  It is like a puzzle I can't quite figure out.
>>> 
>>> Any tips here?  I keep studying the current temp script, but I can't work 
>>> out how to change it into the now playing script.  :)
>>> 
>>> Here is the url I'm working with:
>>> http://www.king.org/pages/4399266
>>> 
>>> Thanks,
>>> Traci
>>> 
>> 
>> -- 
>> ¯\_(ツ)_/¯
>> 
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "MacVisionaries" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to macvisionaries+unsubscr...@googlegroups.com.
>> To post to this group, send email to macvisionaries@googlegroups.com.
>> Visit this group at http://groups.google.com/group/macvisionaries.
>> For more options, visit https://groups.google.com/groups/opt_out.
>> 
>> 
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "MacVisionaries" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to macvisionaries+unsubscr...@googlegroups.com.
> To post to this group, send email to macvisionaries@googlegroups.com.
> Visit this group at http://groups.google.com/group/macvisionaries.
> For more options, visit https://groups.google.com/groups/opt_out.
> 
> 



Have a great day,
Alex (msg sent from Mac Mini)
mehg...@gmail.com



-- 
You received this message because you are subscribed to the Google Groups 
"MacVisionaries" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to macvisionaries+unsubscr...@googlegroups.com.
To post to this group, send email to macvisionaries@googlegroups.com.
Visit this group at http://groups.google.com/group/macvisionaries.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to