Mise en forme d'un texte "a la joce"
Dernière réponse : dans Programmation
salut, j'ai envie de faire un machin qui cree des msg comme sur le forum mais mon niveau de php est a peu pres celui la : http://cit.timone.univ-mrs.fr/ppc/ [
awa']
qqun peut m'expliquer ou m'envoyer un link sur comment mettre en page correctement du texte en php paske des qu ej fous des balises genre
mycy
awa']qqun peut m'expliquer ou m'envoyer un link sur comment mettre en page correctement du texte en php paske des qu ej fous des balises genre
ca me fous des parses errors a la noix c saoulant
<p><font face="Arial" size="4" color=#000066></font></p>
mycy
Autres pages sur : mise forme texte joce
Lassé par la pub ? Créez un compte
Tu veux faire quoi ? Un livre d'or ?
Sache que les variables passées en formulaires s'acquierent de la manière suivante :
$_GET['nom_de_la_variable'] / $_POST['nom_de_la_variable']
(les puristes me diront : il existe $_REQUEST, oui je sais mais je préfère différencier
)
Ensuite, (si c'est toujours le cas) il te faut une base de données ..
Dis en un peu plus sur ce que tu veux faire.
Sache que les variables passées en formulaires s'acquierent de la manière suivante :
$_GET['nom_de_la_variable'] / $_POST['nom_de_la_variable']
(les puristes me diront : il existe $_REQUEST, oui je sais mais je préfère différencier
)Ensuite, (si c'est toujours le cas) il te faut une base de données ..
Dis en un peu plus sur ce que tu veux faire.
le code de ouf :
et j'aimerais l'afficher comme ca :
<html>
<body>
<form method="post" action="zob.php">Entrez votre phrase : <input type="text" name="prout" size="50">
<input type="submit" value="Yeah !">
</form>
</body>
</html>
<?
$prout = $_POST['prout'];
print("<center>$prout</center>");
?>
et j'aimerais l'afficher comme ca :
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" target="_blank">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>">
<html xmlns="<a href="http://www.w3.org/1999/xhtml" target="_blank">http://www.w3.org/1999/xhtml</a>">
<head>
<title>Il est impossible de s'envoyer un message privé à soi même</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<style type="text/css">
.borduresarace
{
border-style:solid;
border-width:1px;
border-color:#CDC9BF;
}
</style>
</head>
<body bgcolor="#FFFFFF">
<br /><br /><br />
<table width="100%" border="0">
<tr>
<td align="center">
<table width="50%" cellspacing="0" cellpadding="0" class="borduresarace">
<tr>
<td bgcolor="#FFFFFF" align="center">
<font face="Arial" size="4" color="#000066">Flo14 is gay !!!</font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>
Bitman1er a écritle code de ouf :
<html>
<body>
<form method="post" action="zob.php">Entrez votre phrase : <input type="text" name="prout" size="50">
<input type="submit" value="Yeah !">
</form>
</body>
</html>
<?
$prout = $_POST['prout'];
print("<center>$prout</center>");
?>
if ( $_POST['submit'] ) {
$prout = stripslashes($_POST['prout']);
echo '<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" target="_blank">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>">
<html xmlns="<a href="http://www.w3.org/1999/xhtml" target="_blank">http://www.w3.org/1999/xhtml</a>">
<head>
<title>' . $prout . '</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<style type="text/css">
.borduresarace
{
border-style:solid;
border-width:1px;
border-color:#CDC9BF;
}
</style>
</head>
<body bgcolor="#FFFFFF">
<br /><br /><br />
<table width="100%" border="0">
<tr>
<td align="center">
<table width="50%" cellspacing="0" cellpadding="0" class="borduresarace">
<tr>
<td bgcolor="#FFFFFF" align="center">
<font face="Arial" size="4" color="#000066">' . $prout . '</font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
} else {
?>
<html>
<body>
<form method="post" action="zob.php">Entrez votre phrase : <input type="text" name="prout" size="50">
<input type="submit" value="Yeah !">
</form>
</body>
</html>
<?
}
?>
brut de fonderie là
nan c pas le cas
bon par contre ca foire ton truc, en fait ca affiche que le else donc la meme chose que les 2 lignes originales
non en fait ca foire
http://cit.timone.univ-mrs.fr/ppc/
bon par contre ca foire ton truc, en fait ca affiche que le else donc la meme chose que les 2 lignes originales
non en fait ca foire
http://cit.timone.univ-mrs.fr/ppc/
Bitman1er a écritnan c pas le cas
bon par contre ca foire ton truc, en fait ca affiche que le else donc la meme chose que les 2 lignes originales
non en fait ca foire
http://cit.timone.univ-mrs.fr/ppc/
bon par contre ca foire ton truc, en fait ca affiche que le else donc la meme chose que les 2 lignes originales
non en fait ca foire
http://cit.timone.univ-mrs.fr/ppc/
ca ca marche :
<?
echo '<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" target="_blank">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>">
<html xmlns="<a href="http://www.w3.org/1999/xhtml" target="_blank">http://www.w3.org/1999/xhtml</a>">
<head>';
if ( $_POST['submit'] ) {
$prout = stripslashes($_POST['prout']);
echo '
<title>' . $prout . '</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<style type="text/css">
.borduresarace
{
border-style:solid;
border-width:1px;
border-color:#CDC9BF;
}
</style>
</head>
<body bgcolor="#FFFFFF">
<br /><br /><br />
<table width="100%" border="0">
<tr>
<td align="center">
<table width="50%" cellspacing="0" cellpadding="0" class="borduresarace">
<tr>
<td bgcolor="#FFFFFF" align="center">
<font face="Arial" size="4" color="#000066">' . $prout . '</font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
} else {
?>
<html>
<body>
<form method="post" action="zob.php">Entrez votre phrase : <input type="text" name="prout" size="50">
<input type="submit" name="submit" value="Yeah !">
</form>
</body>
</html>
<?
}
?>
<?
echo '<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" target="_blank">http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd</a>">
<html xmlns="<a href="http://www.w3.org/1999/xhtml" target="_blank">http://www.w3.org/1999/xhtml</a>">
<head>';
$prout = $_GET['prout'];
echo '
<title>' . $prout . '</title>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<style type="text/css">
.borduresarace
{
border-style:solid;
border-width:1px;
border-color:#CDC9BF;
}
</style>
</head>
<body bgcolor="#FFFFFF">
<br /><br /><br />
<table width="100%" border="0">
<tr>
<td align="center">
<table width="50%" cellspacing="0" cellpadding="0" class="borduresarace">
<tr>
<td bgcolor="#FFFFFF" align="center">
<font face="Arial" size="4" color="#000066">' . $prout . '</font>
</td>
</tr>
</table>
</td>
</tr>
</table>
</body>
</html>';
?>
skylight a écritzob.php?prout=texte
mm good idea but ...http://cit.timone.univ-mrs.fr/ppc/zob.php?prout=test
http://cit.timone.univ-mrs.fr/ppc/zob.php?$prout=test
http://cit.timone.univ-mrs.fr/ppc/zob.php$prout=test
Lassé par la pub ? Créez un compte
- Contenus similaires :
- ForumMise en forme texte html php
- ForumMozilla firefox pas de mise en forme du texte
- ForumVba excel detecter mise en forme texte gras italique
- ForumMise en forme textarea
- ForumMise en forme php
- ForumMise en forme en vba
- ForumMise en forme formulaire
- articlesMise en forme facebook
- ForumMise en forme conditionnelle 4
- ForumMise en forme conditionnelle si et
- Voir plus