Forum Moderators: coopster

Message Too Old, No Replies

Problem with cURL !

         

alex_1986

1:42 am on Jan 23, 2010 (gmt 0)

10+ Year Member



Hello,
I want cURL to example.com and Get All web site hosed ( with IP or Hostname ) but not working ! :(

<form action='index.php'>
<label for='query'>Domain: </label> <input type='text' name='words' id='search_query' size="80" value="" /> <button type='submit'>Reverse Ip Lookup!</button>
</form>

<?
$cc = new cURL();
function stripLargeTags($html){
$searches = array (
"/<!\[CDATA\[(.*)\]\]>/si",
"/<script[^>]*>.*?<\/script>/si",
"/<style[^>]*>.*?<\/style>/si",
"/<code[^>]*>.*?<\/code>/si",
"/<!--.*?-->/s",
"/<table.*?>/s","/<\/table>/s",
"/<td.*?>/s","/<\/td>/s",
"/<th.*?>/s","/<\/th>/s",
"/<tr.*?>/s","/<\/tr>/s",
"/<!.*>/Us","/<link.*>/Us",
"/<div[^>]*>.*?<\/div>/si",
"/<\?.*>/Us"
);
$replace = array();
foreach($searches as $search){
array_push($replace, '');
} reset($searches);
$text = preg_replace($searches, $replace, $html);
return $text;
}
$urlcanlay = stripLargeTags($cc->post('http://www.example/reverse_ip/',$host));

///--------------------------------- Start Func
function geturlclick1($html1){
$searches1 = array (
"/\[<a[^>]*>.*?<\/a>\]/si",
"/\/Whois\//si",
"/Number/si","/Domain \/ Host/si","/Functions/si",
"/<\?.*>/Us"
);
$replace1 = array();
foreach($searches1 as $search1){
array_push($replace1, '<br>');
} reset($searches1);
$text1 = preg_replace($searches1, $replace1, $html1);
return $text1;
}
echo geturlclick1($urlcanlay);
?>

Please Help me ! thx

[edited by: dreamcatcher at 6:26 am (utc) on Jan. 23, 2010]
[edit reason] use example.com, thanks. [/edit]

jatar_k

6:49 pm on Jan 26, 2010 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



what premise are you basing the query on though?