Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re^9: web search for certain data

by Corion (Patriarch)
on Nov 23, 2011 at 20:51 UTC ( [id://939738]=note: print w/replies, xml ) Need Help??


in reply to Re^8: web search for certain data
in thread web search for certain data

What is this line supposed to do:

$url =~ s/&/=/g ;

Are you sure that you want to replace all & in your URL with =? If I remove that line, and much other unnecessary cruft, I see the complete HTML and especially also the relevant META tags:

use strict; use LWP::Simple; #Parsing the http file for the required fields my $url = 'http://content.karger.com/ProdukteDB/produkte.asp?Aktion=Sh +owAbstract&ArtikelNr=6735&Ausgabe=224691&ProduktNr=223832'; #$url =~ s/&/=/g ; #my @url_mod = split('=', $url); #checking for url and increasing article no. warn "Downloading $url"; my $html = get $url; print $html;

Replies are listed 'Best First'.
Re^10: web search for certain data
by pydi (Initiate) on Nov 24, 2011 at 03:04 UTC
    Thanks a lot, that works fine. Now i need to increase no. of Abstract&ArtikelNr , and get data for about 700 numbers.I used split to get the id, so that i can increase and get data.Is there other way to do it.
      Why split and replace when you can construct your URL directly? Just increase (or set) the ArtikelNr, and recreate the URL:
      My $artikel_nr = 12345; my $url= "http://...?ArtikelNr=$artikel_nr&..."; ...

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://939738]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (3)
As of 2024-03-28 18:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found