How to download complete data at once from this website?

shahbaz200

Newbie
Joined
Jul 25, 2015
Messages
25
Reaction score
1
I am able to access data one entry at a time, what I am trying to do is get everything whats accessible at once.

http://WEBSITE/SOMEURL/test.php?cnic=xxxxxxxxx
by inserting some valid numbers in place of xxxxxxxxx i am able to see a data entry. Is this possible to get all the numbers at once?
And I have another url of same website which can only be access by android app, on browsers it gives error of invalid ip address and tells me to download app
http://WEBSITE/SOMEURL/search_num.php?api_key=AAAA&api_pass=BBBB&num=CCCCCCCC
Api key and api pass is same for all entries, putting in valid ccccc gives me data entries when used from app. The problem is one by one is not what I want. I want everything at all!
Can anyone help me? Sorry if wrong section.
 
So do you want to get the data from http://site.com/?key=1, then http://site.com/?key=2 etc. ?

Here is a quick perl script that will go through each page and save the data to a file.

Code:
use LWP::Simple qw(get);
$url = "http://enter.the/url.and?whatever=";
for($i = 0; $i <= 99999999; $i++) { #if you know what the max of the Cs is then replace the 9s with it
    $newurl = "$url"+"$i";
    $data = get $newurl;
    open(my $file, ">", "$i"+".txt");
    print $file $data;
    close $file;
}
 
Back
Top