Définir l'emplacement d'une zone de texte
Résolu
Boum
-
Boum -
Boum -
Bonjour,
Je travaille sur un site simple de comité scolaire et j'ai des connaissances de base en html.
Je souhaite définir précisément l'espace que prendra une zone de texte dans une page.
S'il y a une formule générale pour le faire ce serait génial.
Voici mon code sinon (je désire simplement définir une zone de texte afin que le texte ne piétine pas sur la bordure verte rayée (à gauche))
Merci
S'il vous manque des détails pour me répondre, n'hésitez pas à en demander.
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Comité sur les erreurs judiciaires</title>
<meta http-equiv="Content-type" content="text/html; charset=iso-8859-1">
<style type="text/css">a {text-decoration: none} </style>
<link rel="stylesheet" href="./index.css" type="text/css">
<script type="text/javascript">
<!--
content = new Array ();
content [0] = new Array (
false,
new Array('sub_0_1','sub_0_2','sub_0_3')
);
content [1] = new Array (
false,
new Array('sub_1_1','sub_1_2','sub_1_3')
);
content [2] = new Array (
false,
new Array('sub_2_1','sub_2_2','sub_2_3')
);
isOPERA = (navigator.userAgent.indexOf('Opera') >= 0)? true : false;
isIE = (document.all && !isOPERA)? true : false;
isDOM = (document.getElementById && !isIE && !isOPERA)? true : false;
function processTree (id)
{
if (content [id][0])
{
for (i = 0; i < content [id][1].length; i++)
hide (content [id][1][i]);
content [id][0] = false;
}
else
{
for (i = 0; i < content [id][1].length; i++)
show (content [id][1][i], 'table-row');
content [id][0] = true;
}
return false;
}
function show (id, displayValue)
{
if (isDOM)
document.getElementById(id).style.display = (displayValue)? displayValue : "block";
else if (isIE)
document.all[id].style.display = "block";
}
function hide (id)
{
if (isDOM)
document.getElementById(id).style.display = "none";
else if (isIE)
document.all[id].style.display = "none";
}
if (isDOM || isIE)
{
document.writeln('<style type="text/css">');
document.writeln('.SubItemRow \{ display: none; \}');
}
// -->
</script>
<STYLE TYPE="text/css">
<!--
BODY {background-image:http://img412.imageshack.us/img412/5413/g9brk09ql1.gif; background-repeat:repeat-y}
-->
</STYLE>
</head>
<body bgcolor="#669933" link="#FFFF00" vlink="#FFFF00" text="#CCFF99">
<br>
<center><img src="http://img141.imageshack.us/img141/5649/cej3ee6.gif"></center>
<br>
<table width="80%" align="center" cellspacing=0 border=0 background="http://img138.imageshack.us/img138/5862/essai2ma3.jpg">
<tr>
<td width="100%" colspan=3 align="center" background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif">BIENVENUE
<br><br>Nous travaillons actuellement à la tenue d'un colloque sur le campus.</td>
</tr>
<tr>
<td width="66%" align="justify">
<p>
<span style="font-family: Garamond">
Bienvenue sur le site du Comité sur les Erreurs Judiciaires de la Faculté de droit de l'Université de Montréal
</span></p>
aaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaaaaaa
a
aaaaaaaaaa aaaaaaaaa aaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaa</td>
<td width="33%" rowspan=2 align="center" border=1 color="009900" background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif" valign="top">
<img src="http://img520.imageshack.us/img520/6888/bmp013mpetitsp7.jpg"><br><br>
<font color="#FFFFFF"><span style="font-size:14">Bienvenue</span></font>
<br><br>
<table width=150 height=40 border=0 cellpadding=0 cellspacing=1>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (0); return false;">À propos de nous</a></td>
</tr>
<tr id='sub_0_1' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="a.html">-Le comité</a></td>
</tr>
<tr id='sub_0_2' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="b.html">-Les activités</a></td>
</tr>
<tr id='sub_0_3' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="c.html">-Articles</a></td>
</tr>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (1); return false;">Liens pratiques</a></td>
</tr>
<tr id='sub_1_1' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.umontreal.ca/">-Université de Montréal</a></td>
</tr>
<tr id='sub_1_2' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.aedmontreal.com/">-Association des Étudiants en Droit</a></td>
</tr>
<tr id='sub_1_3' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://innocencecanada.com/">-AIDWYC</a></td>
</tr>
<tr id='sub_1_4' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.justice.gc.ca/eng/404.html">-GRCC</a></td>
</tr>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (2); return false;">Autres</a></td>
</tr><br><br>
</tr>
</table>
<br><br>
<font color="#000000"><span style="font-size:14"><a href="mailto:a@a?subject=A l'attention du Comite sur les Erreurs Judiciaires">Contactez nous</font>
<br><br>
<a href="index.html">Retour à la page d'accueil</a>
<br><br>
<tr>
</tr>
</tr>
</table>
<table width="80%" align="center" cellspacing=0 border=0 bordercolor=green background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif">
</body>
</html>
Je travaille sur un site simple de comité scolaire et j'ai des connaissances de base en html.
Je souhaite définir précisément l'espace que prendra une zone de texte dans une page.
S'il y a une formule générale pour le faire ce serait génial.
Voici mon code sinon (je désire simplement définir une zone de texte afin que le texte ne piétine pas sur la bordure verte rayée (à gauche))
Merci
S'il vous manque des détails pour me répondre, n'hésitez pas à en demander.
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>Comité sur les erreurs judiciaires</title>
<meta http-equiv="Content-type" content="text/html; charset=iso-8859-1">
<style type="text/css">a {text-decoration: none} </style>
<link rel="stylesheet" href="./index.css" type="text/css">
<script type="text/javascript">
<!--
content = new Array ();
content [0] = new Array (
false,
new Array('sub_0_1','sub_0_2','sub_0_3')
);
content [1] = new Array (
false,
new Array('sub_1_1','sub_1_2','sub_1_3')
);
content [2] = new Array (
false,
new Array('sub_2_1','sub_2_2','sub_2_3')
);
isOPERA = (navigator.userAgent.indexOf('Opera') >= 0)? true : false;
isIE = (document.all && !isOPERA)? true : false;
isDOM = (document.getElementById && !isIE && !isOPERA)? true : false;
function processTree (id)
{
if (content [id][0])
{
for (i = 0; i < content [id][1].length; i++)
hide (content [id][1][i]);
content [id][0] = false;
}
else
{
for (i = 0; i < content [id][1].length; i++)
show (content [id][1][i], 'table-row');
content [id][0] = true;
}
return false;
}
function show (id, displayValue)
{
if (isDOM)
document.getElementById(id).style.display = (displayValue)? displayValue : "block";
else if (isIE)
document.all[id].style.display = "block";
}
function hide (id)
{
if (isDOM)
document.getElementById(id).style.display = "none";
else if (isIE)
document.all[id].style.display = "none";
}
if (isDOM || isIE)
{
document.writeln('<style type="text/css">');
document.writeln('.SubItemRow \{ display: none; \}');
}
// -->
</script>
<STYLE TYPE="text/css">
<!--
BODY {background-image:http://img412.imageshack.us/img412/5413/g9brk09ql1.gif; background-repeat:repeat-y}
-->
</STYLE>
</head>
<body bgcolor="#669933" link="#FFFF00" vlink="#FFFF00" text="#CCFF99">
<br>
<center><img src="http://img141.imageshack.us/img141/5649/cej3ee6.gif"></center>
<br>
<table width="80%" align="center" cellspacing=0 border=0 background="http://img138.imageshack.us/img138/5862/essai2ma3.jpg">
<tr>
<td width="100%" colspan=3 align="center" background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif">BIENVENUE
<br><br>Nous travaillons actuellement à la tenue d'un colloque sur le campus.</td>
</tr>
<tr>
<td width="66%" align="justify">
<p>
<span style="font-family: Garamond">
Bienvenue sur le site du Comité sur les Erreurs Judiciaires de la Faculté de droit de l'Université de Montréal
</span></p>
aaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaaaaaa
a
aaaaaaaaaa aaaaaaaaa aaaaaaaaaa aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaa</td>
<td width="33%" rowspan=2 align="center" border=1 color="009900" background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif" valign="top">
<img src="http://img520.imageshack.us/img520/6888/bmp013mpetitsp7.jpg"><br><br>
<font color="#FFFFFF"><span style="font-size:14">Bienvenue</span></font>
<br><br>
<table width=150 height=40 border=0 cellpadding=0 cellspacing=1>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (0); return false;">À propos de nous</a></td>
</tr>
<tr id='sub_0_1' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="a.html">-Le comité</a></td>
</tr>
<tr id='sub_0_2' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="b.html">-Les activités</a></td>
</tr>
<tr id='sub_0_3' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="c.html">-Articles</a></td>
</tr>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (1); return false;">Liens pratiques</a></td>
</tr>
<tr id='sub_1_1' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.umontreal.ca/">-Université de Montréal</a></td>
</tr>
<tr id='sub_1_2' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.aedmontreal.com/">-Association des Étudiants en Droit</a></td>
</tr>
<tr id='sub_1_3' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://innocencecanada.com/">-AIDWYC</a></td>
</tr>
<tr id='sub_1_4' class=SubItemRow>
<td width=10> </td>
<td width=149 height=20 class=SubItem><a href="https://www.justice.gc.ca/eng/404.html">-GRCC</a></td>
</tr>
<tr>
<td width=1 class=Item>+</td>
<td width=149 height=20 class=Item><a href=./ class=Item onClick="processTree (2); return false;">Autres</a></td>
</tr><br><br>
</tr>
</table>
<br><br>
<font color="#000000"><span style="font-size:14"><a href="mailto:a@a?subject=A l'attention du Comite sur les Erreurs Judiciaires">Contactez nous</font>
<br><br>
<a href="index.html">Retour à la page d'accueil</a>
<br><br>
<tr>
</tr>
</tr>
</table>
<table width="80%" align="center" cellspacing=0 border=0 bordercolor=green background="http://img481.imageshack.us/img481/8121/g11line02uo7.gif">
</body>
</html>
A voir également:
- Définir l'emplacement d'une zone de texte
- Alternative zone telechargement - Accueil - Outils
- Texte de chanson gratuit pdf - Télécharger - Vie quotidienne
- Définir google comme page d'accueil - Guide
- Transcription audio en texte word gratuit - Guide
- Excel cellule couleur si condition texte - Guide
3 réponses
Bonjour,
Je te réitère le conseil que je te donnais, passe-la à la validation pour quelques corrections et ma demande simple à satisfaire, le code est plus facile à lire s'il est présenté grâce à ce bouton.
Il existe un moyen très simple d'obtenir ce que tu demandes.
Place le contenu de cette cellule dans une <div> et gère les espacements de ce nouveau bloc
++
Chez moi, le menu ne fonctionne pas et l'arrière-plan de la page ne s'affiche pas.
--
Je te réitère le conseil que je te donnais, passe-la à la validation pour quelques corrections et ma demande simple à satisfaire, le code est plus facile à lire s'il est présenté grâce à ce bouton.
Il existe un moyen très simple d'obtenir ce que tu demandes.
Place le contenu de cette cellule dans une <div> et gère les espacements de ce nouveau bloc
<div style="margin:1em 1em 1em 1.5em;">
<p><span style="font-family: Garamond, serif;">
Bienvenue sur le site du Comité sur les Erreurs Judiciaires de la
Faculté de droit de l'Université de Montréal</span></p>
<p>aaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaa
aaaaaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaa aaaaaaa aaaaaaaaaaaaaaaaaaa
a aaaaaaaaaa aaaaaaaaa aaaaaaaaaa
aaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaa</p>
</div>
Ça peut aussi servir ailleurs.
++
Chez moi, le menu ne fonctionne pas et l'arrière-plan de la page ne s'affiche pas.
--
slt, oula ce code me parait pas exemplaire du tout c'est pour ca que j'ai arreté de le lire, mais ce n'est pas la question ^^
pour une zone de texte c'est :
<textarea type="text" cols="50" rows="6" />
l'attribut cols correspond à la largueur de la zone de texte.
l'attribut rows correspond à la hauteur (nombre de ligne) de la zone de texte
En espérant que ca puisse t'aider..
pour une zone de texte c'est :
<textarea type="text" cols="50" rows="6" />
l'attribut cols correspond à la largueur de la zone de texte.
l'attribut rows correspond à la hauteur (nombre de ligne) de la zone de texte
En espérant que ca puisse t'aider..