CONNEXION
  • RetourJeux
    • Sorties
    • Hit Parade
    • Les + populaires
    • Les + attendus
    • Soluces
    • Tous les Jeux
    • Gaming
  • RetourActu Gaming
    • News
    • Astuces
    • Tests
    • Previews
    • Toute l'actu gaming
  • RetourBons plans
    • Bons plans
    • Bons plans Smartphone
    • Bons plans Hardware
    • Bons plans Image et Son
    • Bons plans Amazon
    • Bons plans Cdiscount
    • Bons plans Decathlon
    • Bons plans Fnac
    • Tous les Bons plans
  • RetourJVTech
    • Actus High-Tech
    • Intelligence Artificielle
    • Smartphones
    • Mobilité urbaine
    • Hardware
    • Image et son
    • Tutoriels
    • Tests produits High-Tech
    • Guides d'achat High-Tech
    • JVTech
  • RetourCulture
    • Actus Culture
    • Culture
  • RetourVidéos
    • A la une
    • Gaming Live
    • Vidéos Tests
    • Vidéos Previews
    • Gameplay
    • Trailers
    • Chroniques
    • Replay Web TV
    • Toutes les vidéos
  • RetourForums
    • Hardware PC
    • PS5
    • Switch 2
    • Xbox Series
    • Switch
    • Pokemon pocket
    • FC 25 Ultimate Team
    • League of Legends
    • Tous les Forums
  • PC
  • PS5
  • Xbox Series
  • Switch 2
  • PS4
  • One
  • Switch
  • iOS
  • Android
  • MMO
  • RPG
  • FPS
En ce moment Genshin Impact Valhalla Breath of the wild Animal Crossing GTA 5 Red dead 2
Liste des sujets

Montrer son IP au visiteur

simcityworld
simcityworld
Niveau 9
15 octobre 2005 à 16:44:39

Bonjour a tous ! Je suis en train de monter mon site ( http://simcityworld.free.fr/PC-ASTUCES/ )

je voudrais faire une partie "outils". le visiteur pour tester sa bande passante, voir sa vitesse de connexion, voir son IP...

Seul probleme, je ne sais pas du tout ou trouver les scipt permettant ceci...

Je suis en HTML. Si quelq´un a ces scripts merci de me les donner !

merci bcp !

spartacus
spartacus
Niveau 9
15 octobre 2005 à 16:53:31

Et bien il me semble qu´il te faille faire une page en PHP pour déja supporter cela (ou en js mais j´en doute).

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:04:16

tu doi passer en php et après il suffit d´intégrer ce bout de code dans ton fichié html :
<? $ip=$_SERVER[´REMOTE_ADDR´];
echo ´Votre adresse ip est : ´.$ip.´ .´ ; ?>

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:06:05

PS: les " " corespondent à des espaces

simcityworld
simcityworld
Niveau 9
15 octobre 2005 à 17:10:23

je peux mettre un lien vers une page PHP sur une page en HTML ?

je peux utiliser mon kit graphique (html) en PHP ?

merci

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:17:57

bien sur bien sur. Une page php ne diffère d´une page html que par le fait que ton serveur va vérifier qu´il n´y pas de code à éxecuté (en php sa va de soi ^^)et s´il y en a un il l´éxécute et donne le résultat en html. Donc tu peux même intégrer le petit script que je t´ai donné dans une page html mais il faut que tu change l´extension en .php . Pour le lien y a aucun prob

simcityworld
simcityworld
Niveau 9
15 octobre 2005 à 17:30:25

j´ai mis ça sous Dreamweaver (le code que tu m´a filer est ver la ligne 118) :

<!--
KIT GRAPHIQUE PAR K-NETWORK
http://www.k-network.com
TELECHARGE SUR KITGRAFIK
http://www.kitgrafik.com
-->

<!-- DEBUT HEADER -->

<HTML>
<!-- DATE DE CREATION: 06/02/2003 -->
<HEAD>
<TITLE>PC-ASTUCES simcityworld.free.fr</TITLE>
<META NAME="Author" CONTENT="k.network pour kitgrafik.com">
<STYLE TYPE=text/css>
.texte, TD { font-family:Verdana;font-size:11px;color:white }
.menu { font-family:Verdana;font-size:12px;color:black }
.titre { font-family:Verdana;font-size:20px;color:white }
A.menu {
font-family:Verdana;font-size:11px;color:black;tex
t-decoration:none }
A:hover.menu { font-family:Verdana;font-size:11px;color:#FF9900 }
A {
font-family:Verdana;font-size:11px;color:#FFCC00;t
ext-decoration:none }
A:hover { font-family:Verdana;font-size:11px;color:#CC0000 }
</STYLE>
</HEAD>
<BODY BACKGROUND="images/fond.gif" BGCOLOR=#000000 LEFTMARGIN=0 MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0>
<CENTER>
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=711>
<TR>
<TD COLSPAN=3><TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=711>
<TR>
<TD WIDTH=36><IMG SRC="images/hg.gif" BORDER=0 HSPACE=0 VSPACE=0 width="36" height="77"></TD><TD WIDTH=350 BACKGROUND=images/fond_titre.gif ALIGN=center CLASS=titre>
<!-- ICI, CHANGEZ VOTRE TITRE : -->
PC-ASTUCES simcityworld<BR><IMG SRC="images/pix.gif" BORDER=0 WIDTH=2 HEIGHT=3></TD><TD WIDTH=325>
<IMG SRC="images/hd_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="325" height="77"></TD>
</TR>
</TABLE></TD>
</TR>
<TR>
<TD COLSPAN=3><IMG SRC="images/m_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="711" height="10"></TD>
</TR>
<TR>
<TD WIDTH=147 BACKGROUND=images/menu_fond.gif BGCOLOR=#BFBFBF VALIGN=top><BR>
<!-- DEBUT MENU -->
<!-- DEBUT MENU 1 -->
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=147>
<TR>
<TD BACKGROUND=images/menu.gif HEIGHT=22 CLASS=menu><B>  News</B></TD>
</TR>
<TR>
<TD><IMG SRC="images/menu_und_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="147" height="16"></TD>
</TR>
</TABLE>
 <font color="#000000"><a href="article.html"><font color="#0000FF">Articles</font></a></font><p>
<font color="#000000"> humour :</font></p>
<p><font color="#0000FF"> <a href="perles-tchat.html"><font color="#0000FF">les
perles du tchat</font></a></font></p>
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=147>
<TR>
<TD BACKGROUND=images/menu.gif HEIGHT=22 CLASS=menu><B>  MENU</B></TD>
</TR>
<TR>
<TD><IMG SRC="images/menu_und_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="147" height="16"></TD>
</TR>
</TABLE>
 <font color="#000000"> <a href="index.html"><font color="#0000FF">
Accueil</font></a></font><p><font color="#0000FF">  </font>
<font color="#000000"><a href="explication.html"><font color="#0000FF">
Pourquoi tout cela ?< /font></a></font><font color="#0000FF"><BR>
  </font><font color="#000000"><a href="secur.html">
<font color="#0000FF">Sécurité</font></a><font color="#0000FF"><BR>
  </font></font><a href="optim.html"><font color="#0000FF">O</font></a><font color="#000000"><a href="optim.html"><font color="#0000FF">ptimisation</font></a><font color="#0000FF"><BR>
  </font></font><a href="entretien.html"><font color="#0000FF">E</font></a><font color="#000000"><a href="entretien.html"><font color="#0000FF">ntretien</font></a><font color="#0000FF"><BR>  </font>
<a href="dls.html"><font
color="#0000FF">Téléchargements</font></a></font><
BR>
<!-- FIN MENU 2 -->

<!-- DEBUT MENU 3 -->
</p>
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=147>
<TR>
<TD BACKGROUND=images/menu.gif HEIGHT=22 CLASS=menu><B> 
Ressources</B></TD>
</TR>
<TR>
<TD><IMG SRC="images/menu_und_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="147" height="16"></TD>
</TR>
</TABLE>
 
<a
href="http://www.i-services.net/membres/forum/somm
aire.php?user=86759"><font color="#0000FF">Forum</font></a><font color="#0000FF"><BR>
  </font>
<a
href="http://www.i-services.net/membres/livredor/l
ivredor.php?user=86759"><font color="#0000FF">Livre d´or</font></a><font color="#0000FF"><BR>
  </font><a href="thxto.html"><font color="#0000FF">R</font></a><font color="#000000"><a href="thxto.html"><font
color="#0000FF">emerciements</font></a></font><fon
t color="#0000FF"><BR>
  </font><a href="links.html"><font color="#0000FF">Liens</font></a><font color="#0000FF"><BR> 
</font>
<font color="#000000"><a href="contact.html"><font color="#0000FF">Contact</font></a></font><BR>
<!-- FIN MENU 3 -->

<!-- FIN MENU -->
</TD>
<TD BGCOLOR=#5E5E5E WIDTH=530 VALIGN=top STYLE="padding:5"><IMG SRC="images/pix.gif" BORDER=0 WIDTH=2 HEIGHT=10 HSPACE=0 VSPACE=0><BR>
<!-- FIN HEADER -->

<!-- DEBUT SECTION 1 -->
<TABLE CELLPADDING=0 CELLSPACING=0 BORDER=0 WIDTH=495>
<TR>
<TD BACKGROUND=images/se.gif HEIGHT=22 CLASS=menu><b>Contactez-moi</b></TD>
</TR>
<TR>
<TD><IMG SRC="images/sec_jau.gif" BORDER=0 HSPACE=0 VSPACE=0 width="495" height="12"><BR><IMG SRC="images/pix.gif" BORDER=0 WIDTH=2 HEIGHT=5 HSPACE=0 VSPACE=0></TD>
</TR>
</TABLE>
 <p>
<IMG SRC="images/puce.gif" BORDER=0 HSPACE=0 VSPACE=0 width="9" height="9">
</p>
<? $ip=$_SERVER[´REMOTE_ADDR´];
echo ´Votre adresse ip est : ´.$ip.´ .´ ; ?>
<p><BR><BR><BR><BR><BR><BR><BR>

<!-- FIN SECTION 3 -->

<!-- DEBUT FOOTER -->
</TD>
<TD WIDTH=34 BACKGROUND=images/d.gif BGCOLOR=#BFBFBF>
<IMG SRC="images/d.gif" BORDER=0 HSPACE=0 VSPACE=0 width="34" height="92"></TD>
</TR>
<TR>
<TD COLSPAN=3><IMG SRC="images/bas.gif" BORDER=0 HSPACE=0 VSPACE=0 width="711" height="19"></TD>
</TR>
</TABLE><DIV ALIGN="center" CLASS=texte>Design © 2003 <A HREF="http://www.k-network.com" TARGET="_blank">K-Network</A> pour <A HREF="http://www.kitgrafik.com" TARGET="_blank">KitGrafik</A></DIV>
</CENTER>
</BODY>
</HTML>
<!-- FIN FOOTER -->

et ça donne :

Parse error: parse error, unexpected T_STRING, expecting ´,´ or ´;´ in
/var/www/free.fr/4/5/simcityworld/PC-ASTUCES/outil
s.php on line 118

qu´est ce qui ce passe ?

merci pour vos réponses

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:35:48

y a une erreur quelque part je te le refais et reéssaye
<? $ip=$_SERVER[´REMOTE_ADDR´];
echo ´Votre adresse ip est : ´.$ip ; ?>

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:39:57

quand tu fais le copié collé remplace les accents graves par des ´ (apostrophes)

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:44:14

voila ct ça le problème faut que tu remplace tous les accents graves qui a dans mon codes par des apostrophes. J´ai testé et ce code marche (avec des apostrophes bien sur)
<? $ip=$_SERVER[´REMOTE_ADDR´];
echo ´Votre adresse ip est : ´ ;
echo $ip ; ?>

simcityworld
simcityworld
Niveau 9
15 octobre 2005 à 17:48:20

ok c´est bon ça marche !! merci !

Et les autres scripts ? test de bande passante, test de connexion...

merci

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:49:59

sa c en dehors de mes capacités dsl

simcityworld
simcityworld
Niveau 9
15 octobre 2005 à 17:50:52

pas grave ta deja fait bcp merci

A-spec59
A-spec59
Niveau 10
15 octobre 2005 à 17:51:47

essaye de contacter les sites qui les font ces tests et demande leur comment ils font où cherche sur google y a peut être

le_skateur0
le_skateur0
Niveau 8
08 novembre 2005 à 20:40:34

peut on metre du PHP dans une page xhtml?

captain_torche
captain_torche
Niveau 10
08 novembre 2005 à 22:08:24

Oui, si tu renommes la page en .php (et que ton hébergeur le supporte).

Sous forums
  • Aide à l'achat Mac
  • Création de Jeux
  • Linux
  • Programmation
  • Création de sites web
  • Internet
  • Steam Deck
  • Macintosh
  • Hardware