1. Welcome to the new MacRumors forums. See our announcement and read our FAQ

trying to compare url sourcecode in applescript

Discussion in 'Mac Programming' started by sinfulboi, Dec 22, 2006.

  1. macrumors newbie

    #1
    hey there im just a newbie to applescript and was wondering if there was a simple way of grabbing the url from an online source and then comparing it to one on my harddrive.

    just viewing the source of the page would be a great start so if there is anyone out there who can help me... please... dont be shy ;)
     
  2. macrumors G3

    iMeowbot

    #2
    I don;t think I'd have the patience to make something like that happen in Applescript :p :D

    There are two nice little shell commands, curl and diff, that would make this kind of thing really easy. You can run those from Applescript, if you prefer.
     
  3. macrumors newbie

    #3
    thank you... i spose since i am new to the whole applescript world i am keen to try and do everything in it... but is there no easy way just to save the page source of a url to a file?
     
  4. macrumors 68040

    mduser63

    #4
    Yes, with curl. You can easily call commands like curl using the AppleScript syntax:

    do shell script "put your shell script here"
     

Share This Page