So I decided to try out the basic refresher just to start. Hopefully I will get some good RE's with it. I downloaded it, but when i tried to use it, it said I couldn't or something. Any suggestions on what is wrong? Also I apologize if this is the wrong board for it. Like i said, im new to this.
Nope if it gives you the runtime error 13 type mismatch then it will not work. The httpwrapper that is uses will not work anymore so it is broken permatly
ok well i bought a new one. this one downloaded, and when i clicked on it, this box of text popped up. Now what do i do? :shock:
Prob like what was said, it is broken and you may as well go to the help forum for suggestions or maybe just get something else. Hope this helps.
it said this: #!/usr/local/bin/perl use LWP; use HTTP::Cookies; #Author Karl S. #Date 28/9/2006 #Information Neopets Refresher #Initiate global objects my $baseurl = "http://neopets.com"; #Neopets base URL my $spiderurl = "/explore.phtml"; #Neopets base URL my $waittime = 1; #Wait time my $regexmatch = qr#href=\"(/.*?\.phtml)\"#; #Compile the regex and store it - allows for faster execution later on my $regexlogin = qr/Welcome, /; #Compile the regex and store it - allows for faster execution later on my $regexloginerr = qr/That\s*<.*>\s*<.*>\s*(.*)\s*<.*>\s*<.*>\s*combination is invalid\./; #Compile the regex and store it - allows for faster execution later on my $ua = LWP::UserAgent->new; #Build the ua obj $ua->env_proxy(); #Check for a proxy running on your system/network $ua->agent("Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.7) Gecko/20060909 Firefox/1.5.0.7"); #Set the useragent to the default Firefox ua $ua->cookie_jar(HTTP::Cookies->new); #Use cookies push @{$ua->requests_redirectable}, 'POST'; #Allow POST requests to be redirected by the server(for login) #Ask for username & password on terminal quit("Usage: $0 <username> <password> <macrotimeinsecs>") if $#ARGV < 2 or $ARGV[2] =~ /\D+/; my ($username, $password, $waittime) = @ARGV; &test; login($username, $password); spider($spiderurl); sub test{ my $url = "www.google.com"; my $req = HTTP::Request->new(GET => $url); $req->referer("http://www.google.com"); } sub login { my $username = shift; my $password = shift; my $loginurl = $baseurl . "/login.phtml"; print "Logging in with <" . $username . "> and <*******> ... "; my $post = $ua->post($loginurl, [ "username" => $username, "password" => $password ], ); if($post->is_success){ if($post->content =~ $regexlogin){ print "Logged in!\r\n"; }else{ print "Could not log in: $1 invalid\r\n" if $post->content =~ $regexloginerr; exit; } }else{ die "Error: ", $post->status_line; } } sub spider { my $startpage = shift; print "Going to: $startpage\n"; my $get = $ua->get($baseurl . $startpage); if($get->is_success){ if(my @matches = $get->content =~ /$regexmatch/g){ if($#matches >= 0){ my $index = int(rand($#matches)); if($matches[$index] =~ m{http://www\.neopets\.com/.*}){ sleep $waittime; spider($spiderurl); } sleep $waittime; spider($matches[$index]); }else{ sleep $waittime; spider($spiderurl); } } } } sub quit { my $msg = shift; print $msg; exit; }
Aww, what if I buy a program and it doesn't work? will i get my points back? (sorry, i'm new to the site =)