Script php
isabelle
-
alain1967 Messages postés 9 Date d'inscription Statut Membre Dernière intervention -
alain1967 Messages postés 9 Date d'inscription Statut Membre Dernière intervention -
Bonjour,
sil vous palit aide moi
jinstaller moteur de recherche qui vérifier la disponibilité de nom de domaine dans mon site j'ajoute cette script
<?php
$result = '';
$theNdd = trim($_POST['theNdd']);
$theExt = $_POST['theExt'];
if (!empty($theNdd) AND !empty($theExt)) {
$theNdd = preg_replace(array( '/http:\/\/www\./',
'/http:\/\//',
'/www\./' ),
array( '', '', '') ,$theNdd);
$theNdd = preg_replace(array( '/\.eu/',
'/\.fr/',
'/\.com/',
'/\.net/',
'/\.org/',
'/\.info/',
'/\.biz/',
'/\.de/',
'/\.me.uk/',
'/\.co.uk/',
'/\.org.uk/',
'/\.ca/' ),
array( '', '', '', '', '', '', '', '', '', '', '', '') ,$theNdd);
78 $theNdd = escapeshellcmd($theNdd);
//on definit les case du tableau à vérifier
$caseForVerif['.net']=7;
$caseForVerif['.com']=7;
$caseForVerif['.org']=0;
$caseForVerif['.fr']=13;
$caseForVerif['.ca']=5;
$caseForVerif['.info']=0;
$caseForVerif['.biz']=1;
$caseForVerif['.de']=35;
$caseForVerif['.eu']=50;
$caseForVerif['.me.uk']=30;
$caseForVerif['.co.uk']=30;
$caseForVerif['.org.uk']=40;
//on definit les phrase à vérifier dans ces cases
$strForVerif['.com']='No match for "'.$theNdd.'.COM".';
$strForVerif['.fr']='%% No entries found in the AFNIC Database.';
$strForVerif['.net']='No match for "'.$theNdd.'.NET".';
$strForVerif['.org']='NOT FOUND';
$strForVerif['.ca']='';
$strForVerif['.info']='NOT FOUND';
$strForVerif['.biz']='';
$strForVerif['.de']='';
$strForVerif['.eu']='';
$strForVerif['.me.uk']='';
$strForVerif['.co.uk']='';
$strForVerif['.org.uk']='';
foreach($theExt as $anExt) {
$myArray="";
101 $anExt=escapeshellcmd($anExt);
102 exec('whois '.$theNdd.$anExt,$myArray,$retval);
$result.=(strtolower($myArray[$caseForVerif[$anExt]])==strtolower($strForVerif[$anExt]))?"->> ".$theNdd.$anExt." est libre<br/>":"->> ".$theNdd.$anExt." est déjà réservé<br />";
}
}
?>
<form action="<?php echo $_SERVER['REQUEST_URI']; ?>" name="formVeirfNdd" enctype="multipart/form-data" method="post">
www.<input type="text" name="theNdd" value="<?php echo $theNdd; ?>" />
<input name="theExt[]" type="checkbox" value=".com" id="com" checked><label for="com">.com</label>
<input name="theExt[]" type="checkbox" value=".eu" id="eu"><label for="eu">.eu</label>
<input name="theExt[]" type="checkbox" value=".fr" id="fr"><label for="fr">.fr</label>
<input name="theExt[]" type="checkbox" value=".net" id="net"><label for="net">.net</label>
<input name="theExt[]" type="checkbox" value=".org" id="org"><label for="org">.org</label>
<input name="theExt[]" type="checkbox" value=".info" id="info"><label for="info">.info</label>
<input name="theExt[]" type="checkbox" value=".ca" id="ca"><label for="ca">.ca</label>
<input name="theExt[]" type="checkbox" value=".biz" id="biz"><label for="biz">.biz</label>
<input name="theExt[]" type="checkbox" value=".de" id="de"><label for="de">.de</label>
<input name="theExt[]" type="checkbox" value=".me.uk" id="me.uk"><label for="me.uk">me.uk</label>
<input name="theExt[]" type="checkbox" value=".co.uk" id="co.uk"><label for="co.uk">co.uk</label>
<input name="theExt[]" type="checkbox" value=".org.uk" id="org.uk"><label for="org.uk">org.uk</label>
<input type="submit" value="Vérifier">
</form>
<?php echo '<h3>'.$result.'</h3>'; ?>
mé aprés la discution il écrit ça
Warning: escapeshellcmd() has been disabled for security reasons in /home/whois.php on line 72
Warning: escapeshellcmd() has been disabled for security reasons in /home/whois.php on line 101
Warning: exec() has been disabled for security reasons in /home/whois.php on line 102
sil vous pait aide moi
sil vous palit aide moi
jinstaller moteur de recherche qui vérifier la disponibilité de nom de domaine dans mon site j'ajoute cette script
<?php
$result = '';
$theNdd = trim($_POST['theNdd']);
$theExt = $_POST['theExt'];
if (!empty($theNdd) AND !empty($theExt)) {
$theNdd = preg_replace(array( '/http:\/\/www\./',
'/http:\/\//',
'/www\./' ),
array( '', '', '') ,$theNdd);
$theNdd = preg_replace(array( '/\.eu/',
'/\.fr/',
'/\.com/',
'/\.net/',
'/\.org/',
'/\.info/',
'/\.biz/',
'/\.de/',
'/\.me.uk/',
'/\.co.uk/',
'/\.org.uk/',
'/\.ca/' ),
array( '', '', '', '', '', '', '', '', '', '', '', '') ,$theNdd);
78 $theNdd = escapeshellcmd($theNdd);
//on definit les case du tableau à vérifier
$caseForVerif['.net']=7;
$caseForVerif['.com']=7;
$caseForVerif['.org']=0;
$caseForVerif['.fr']=13;
$caseForVerif['.ca']=5;
$caseForVerif['.info']=0;
$caseForVerif['.biz']=1;
$caseForVerif['.de']=35;
$caseForVerif['.eu']=50;
$caseForVerif['.me.uk']=30;
$caseForVerif['.co.uk']=30;
$caseForVerif['.org.uk']=40;
//on definit les phrase à vérifier dans ces cases
$strForVerif['.com']='No match for "'.$theNdd.'.COM".';
$strForVerif['.fr']='%% No entries found in the AFNIC Database.';
$strForVerif['.net']='No match for "'.$theNdd.'.NET".';
$strForVerif['.org']='NOT FOUND';
$strForVerif['.ca']='';
$strForVerif['.info']='NOT FOUND';
$strForVerif['.biz']='';
$strForVerif['.de']='';
$strForVerif['.eu']='';
$strForVerif['.me.uk']='';
$strForVerif['.co.uk']='';
$strForVerif['.org.uk']='';
foreach($theExt as $anExt) {
$myArray="";
101 $anExt=escapeshellcmd($anExt);
102 exec('whois '.$theNdd.$anExt,$myArray,$retval);
$result.=(strtolower($myArray[$caseForVerif[$anExt]])==strtolower($strForVerif[$anExt]))?"->> ".$theNdd.$anExt." est libre<br/>":"->> ".$theNdd.$anExt." est déjà réservé<br />";
}
}
?>
<form action="<?php echo $_SERVER['REQUEST_URI']; ?>" name="formVeirfNdd" enctype="multipart/form-data" method="post">
www.<input type="text" name="theNdd" value="<?php echo $theNdd; ?>" />
<input name="theExt[]" type="checkbox" value=".com" id="com" checked><label for="com">.com</label>
<input name="theExt[]" type="checkbox" value=".eu" id="eu"><label for="eu">.eu</label>
<input name="theExt[]" type="checkbox" value=".fr" id="fr"><label for="fr">.fr</label>
<input name="theExt[]" type="checkbox" value=".net" id="net"><label for="net">.net</label>
<input name="theExt[]" type="checkbox" value=".org" id="org"><label for="org">.org</label>
<input name="theExt[]" type="checkbox" value=".info" id="info"><label for="info">.info</label>
<input name="theExt[]" type="checkbox" value=".ca" id="ca"><label for="ca">.ca</label>
<input name="theExt[]" type="checkbox" value=".biz" id="biz"><label for="biz">.biz</label>
<input name="theExt[]" type="checkbox" value=".de" id="de"><label for="de">.de</label>
<input name="theExt[]" type="checkbox" value=".me.uk" id="me.uk"><label for="me.uk">me.uk</label>
<input name="theExt[]" type="checkbox" value=".co.uk" id="co.uk"><label for="co.uk">co.uk</label>
<input name="theExt[]" type="checkbox" value=".org.uk" id="org.uk"><label for="org.uk">org.uk</label>
<input type="submit" value="Vérifier">
</form>
<?php echo '<h3>'.$result.'</h3>'; ?>
mé aprés la discution il écrit ça
Warning: escapeshellcmd() has been disabled for security reasons in /home/whois.php on line 72
Warning: escapeshellcmd() has been disabled for security reasons in /home/whois.php on line 101
Warning: exec() has been disabled for security reasons in /home/whois.php on line 102
sil vous pait aide moi
A voir également:
- Script php
- Script vidéo youtube - Guide
- Easy php - Télécharger - Divers Web & Internet
- Mas script - Accueil - Windows
- Ghost script - Télécharger - Polices de caractères
- Expert php pinterest - Télécharger - Langages
1 réponse
Bonjour,
as tu vérifié si les options dans ton php.ini "disable_functions" et "safe_mode_exec_dir" ne desactivent pas par hasard tes fonctions. En fait ici http://www.infosprog.com/php/exec/ ils expliquent que ces options sont parfois mises par défaut et provoquent le même message d'erreur que toi au niveau du exec. Peut être en est il de même pour escapeshellcmd.
as tu vérifié si les options dans ton php.ini "disable_functions" et "safe_mode_exec_dir" ne desactivent pas par hasard tes fonctions. En fait ici http://www.infosprog.com/php/exec/ ils expliquent que ces options sont parfois mises par défaut et provoquent le même message d'erreur que toi au niveau du exec. Peut être en est il de même pour escapeshellcmd.