Bonjour,

je suis le développeur de CrawlTrack, qui nécessite l'utilisation d'un tag en php. Pour pouvoir répondre à la demande de plusieurs utilisateurs de site programmés en Asp il faudrait que je propose un tag compatible. Voici la version du tag qui utilise une requète http et qui serait donc adaptée dans ce cas, est-ce que quelqu'un eux m'aider pour faire la conversion en Asp?
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
 
error_reporting(0);
$crawlturl =urlencode($_SERVER['REQUEST_URI']);
$crawltagent =urlencode($_SERVER['HTTP_USER_AGENT']);
$crawltip = urlencode($_SERVER['REMOTE_ADDR']);
$crawltreferer=urlencode($_SERVER['HTTP_REFERER']);
$crawltvariablescodees = "url=".$crawlturl."&agent=".$crawltagent."&ip=".$crawltip."&referer=".$crawltreferer."&site=2";
$url_crawlt2=parse_url("http://www.xxxxx.fr/xxxxxx/crawltrack.php");
$crawlthote=$url_crawlt2['host'];
$crawltscript=$url_crawlt2['path'];
$crawltentete = "POST ".$crawltscript." HTTP/1.1\r\n";
$crawltentete .= "Host: ".$crawlthote." \r\n";
$crawltentete .= "Content-Type: application/x-www-form-urlencoded\r\n";
$crawltentete .= "Content-Length: " . strlen($crawltvariablescodees) . "\r\n";
$crawltentete .= "Connection: close\r\n\r\n";
$crawltentete .= $crawltvariablescodees . "\r\n";
$crawltsocket = fsockopen($url_crawlt2['host'], 80, $errno, $errstr);
$crawltreply="";
if($crawltsocket)
{
fputs($crawltsocket, $crawltentete);
while (!feof($crawltsocket)) {
$crawltreply.= fgets($crawltsocket,128);
}
fclose($crawltsocket);
}
if(strpos($crawltreply, 'crawltrack'))
{
$crawltreply2 = explode('crawltrack', $crawltreply);
$crawltreply3=$crawltreply2[1];
}
else
{
$crawltreply3=0;
}
if($crawltreply3==1)
{
$GLOBALS = array();
$_COOKIES = array();
$_FILES = array();
$_ENV = array();
$_REQUEST = array();
$_POST = array();
$_GET = array();
$_SERVER = array();
$_SESSION = array();
@session_destroy();
@mysql_close();
@header("Location:http://www.xxxxx.fr/xxxxx/html/noacces.htm");
echo"<head>";
echo"<META HTTP-EQUIV='Refresh' CONTENT='0;URL=http://www.xxxxxx.fr/xxxxx/html/noacces.htm'>";
echo"</head>";
}
Merci d'avance.

Jean-Denis