fetching images manually from a website that uses a sessionid variable

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • C3

    fetching images manually from a website that uses a sessionid variable

    Hi everone.

    I'm trying to write a shell script that fetches a number of images from a
    map website (www.whereis.com.au). Basically, the page asks you for a street
    address and then queries the server in a strange way, and then displays the
    map you asked for. It then allows you to scroll in different directions from
    that map.

    My aim is to be able to write a program that will take a street address,
    query the website, and return the initial map, and the 8 maps around it. The
    problem is that I can't figure out how the query works. Here is a little
    snippet (which I captured with ethereal). This is the initial request, with
    the address "200 arden street randwick":

    POST
    /search/result.jhtml;$s essionid$TREFXT YAABL4RS0Z2WLCD TI?_DARGS=%2Fse arch%2Fr
    esult.jhtml HTTP/1.1
    Host: www.whereis.com.au
    <various browser headers>
    Referer:
    http://www.whereis.com .au/search/result.jhtml;$s essionid$TREFXT YAABL4RS0Z2WL
    CDTI?_DARGS=%2F search%2Fsearch .jhtml.2
    Content-Type: application/x-www-form-urlencoded
    Content-Length: 1067

    streetNumber=+2 00&_D%3AstreetN umber=+&streetN ame=arden&_D%3A streetName=+&st r
    eetType=ST&_D%3 AstreetType=+&l ocality=randwic k&_D%3Alocality =+&postCode=203 1
    &_D%3ApostCode= +&message=&_D%3 Amessage=+&erro rPage=result.jh tml&_D%3AerrorP a
    ge=+&searchBlob =1%2Chttp%3A%2F %2Fmap3.whereis .com.au%2Ftelma p%2Fmap%2Fmap22 9
    59.gif%2Chttp%3 A%2F%2Fmap3.whe reis.com.au%2Ft elmap%2Fmap%2Fc map22959.gif%2C 2
    57+H12%2C255%2C 3%2C4.0000%2C13 04%2C920%2C3389 18.3%2C6246113. 8%2C151.25759%2 C
    -33.91297%2C0%2C SYDNEY%2C9351%2 C2%2C0%2C1%2C1% 2C3000011%3A151 .25759%3A-33.91
    297&_D%3Asearch Blob=+&blob=1%2 Chttp%3A%2F%2Fm ap3.whereis.com .au%2Ftelmap%2F m
    ap%2Fmap22959.g if%2Chttp%3A%2F %2Fmap3.whereis .com.au%2Ftelma p%2Fmap%2Fcmap2 2
    959.gif%2C257+H 12%2C255%2C3%2C 4.0000%2C1304%2 C920%2C338918.3 %2C6246113.8%2C 1
    51.25759%2C-33.91297%2C0%2C SYDNEY%2C9351%2 C2%2C0%2C1%2C1% 2C3000011%3A151 .257
    59%3A-33.91297&_D%3Ab lob=+&command=P AN&_D%3Acommand =+&action=SEARC H&panDirec
    tion=E&zoomLeve l=2&legend=&pro ximitySearchTyp e=&_D%3Aproximi tySearchType=+& _
    D%3ArecenterPoi nt=+&proximityS earchID=0&_D%3A advertiserID=+& _D%3Aadvertiser I
    D=+


    Now, I can obviously see my search parameters in there, but how would I use
    these in lynx to get the initial webpage? Can I just take these all as POST
    variables, or is there something I have to do with the sessionid?


    thanks,





Working...