program for google search
i mean to use (i.e) google to find site and then to save the urls(i.e: http://hel…. , http://yahoo.com…. ) in a txt file and not click , when i want to see the sites…. ( i want to use a program to open the sites i have found in google search from a txt file….:p
<?php $mystring = "Microsoft"; $fp1 = fopen('/…../something.txt', 'r'); $fp2 = fopen('/………….l/something2.txt', 'w');
while($buffer = fscanf($fp1, "%s")){ list($url)=$buffer; echo '<script>alert("Open the url..:'.$url.'")</script>';
$handle = fopen( $url, "r" ); $contents = stream_get_contents( $handle ); $c = str_word_count( $contents ); if( eregi( $mystring, $contents ) ){
echo "<script>alert(\"'" . $mystring . "' found!\")</script>\n";
echo '<script>window.open("'.$url.'");</script>';
echo "Word count: " . $c . "\n";}
fwrite($fp2,$url."\n");
}
fclose($fp1); fclose($fp2);
?>
the something.txt is the txt file , from that i take the url i want to inject… and in the something2.txt write the url is vuln.. but i have on other problem… when i add in url the " ' " (i.e:http://www.conservationregister.com/login.asp?id='" he returns the server:Warning: fopen(http://www.conservationregister.com/login.asp?id=') [function.fopen]: failed to open stream: HTTP request failed! HTTP/1.1 500 Internal Server Error in /…../dokimes/dokimi2.php on line 5…. how can i solve this problem????
@op:
I made this for you: http://pastebin.com/f4bf04467 Your mom said it was your birthday.
edit: If you were really anal, you could also add ftp:// to it.
can anyone help me to solve the problem: when i add in url the " ' " (i.e:http://www.conservationregister.com/login.asp?id='" he returns the server:Warning: fopen(http://www.conservationregister.com/login.asp?id=') [function.fopen]: failed to open stream: HTTP request failed! HTTP/1.1 500 Internal Server Error in /…../dokimes/dokimi2.php on line 5…. i use the xampp and i made my pc server!!!!…
please help me with this script in php: We have this txt file and we wont to get the http://65.127.137.224/board/login.asp?id=dd… with whose commands in php we can do this????
<h2 class=r><a href="http://65.127.137.224/board/login.asp?id=dd" class=l onmousedown="return clk(this.href,'','','res','1','')">Family Federation for World Peace and Unification of U.S.A.</a></h2>
Why exactly are you wanting to do this versus using google its self? Yeah it's possible, it would be a hefty script probably in PHP. U'r probbly gonna have to use preg_match_all but there will be some big limitations like you can probably only return the first page of results. I can see it being possible, I can see it being a HUGE pain in the ass to script too though.
how can i cut the url http://65.127.137.224/board/login.asp?id=dd from the txt file bellow … with php script??? i read a lot of forums in php but i'm confused about this… any help??
<h2 class=r><a href="http://65.127.137.224/board/login.asp?id=dd" class=l onmousedown="return clk(this.href,'','','res','1','')">Family Federation for World Peace and Unification of U.S.A.</a></h2>