 |
|
|
| View previous topic :: View next topic |
| Author |
Message |
georgex5
Joined: 30 Jan 2008 Posts: 11
|
Posted: Fri Feb 08, 2008 11:45 am How to: Remove empty line of text? |
|
|
|
I am trying to set up a manuscript in play format using html.
The format I would like to use is:
(Indent to about the center of the page)AL
On the next line type what AL says.
I have the following:
<p class="two">AL</span><p>Hello.
This give me AL centered but then it adds a line and then Hello on the next line.
I want to get rid of the empty line between centered AL and flush left Hello on the next line.
The code is based on:
Code:
<style type="text/css">
.one{
text-indent:60px;
font-style:normal;
}
.two{
text-indent:80px;
font-style:normal;
}
</style>
Would appreciate comments. |
|
madprof
Joined: 26 Jan 2008 Posts: 98
|
Posted: Fri Feb 08, 2008 12:22 pm |
|
|
|
OK firstly you'll need "well-formed" HTML to make sense of it. Additionally there are HTML elements which may be of more use to you.
Try:
| Code: |
<dl id="mylist">
<dt>AL</dt>
<dd>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean vel leo sit amet lorem fermentum congue. Nullam sed pede. Morbi fringilla placerat odio. Phasellus posuere justo.</dd>
</dl>
|
I'm kind of assuming you'll have more than one of these to show so would want a list.
If so, you want CSS something like:
| Code: |
#mylist dt { margin-left: 80px; }
|
Then again if you just want one you could try:
| Code: |
<p id="indentthis">AL<br>
Next line of text which sits right underneath it.</p>
|
With the same as you had before:
| Code: |
#indentthis { text-indent: 80px; }
|
The problem with your current code is that for every <p> tag it implies a </p> and of course paragraphs are styled by default to have spacing around them - which is what you'd expect for paragraphs.
Also the </span> tag seems a bit mislaid, you can remove this with impunity!
Let me know if this works out for you. |
|
georgex5
Joined: 30 Jan 2008 Posts: 11
|
Posted: Fri Feb 08, 2008 12:35 pm |
|
|
|
Actually, I don't think I need a list. I also found that the following gives me what I want:
<p class="one">AL<br>
(Wakes) Why are you rocking my chair?
which is:
AL
(Wakes) Why are you rocking my chair.
This is the code I used:
Code:
<style type="text/css">
.one{
text-indent:80px;
font-style:normal;
}
.two{
text-indent:40px;
font-style:normal;
}
</style>
The 40px is supposed to indent about half as far as the 80px.
For some reason, it doesn't indent at all. Why? |
|
madprof
Joined: 26 Jan 2008 Posts: 98
|
Posted: Fri Feb 08, 2008 12:48 pm |
|
|
|
| If you show me the HTML in full and the CSS in full I could tell you. Without that it's impossible to say I'm afraid. |
|
georgex5
Joined: 30 Jan 2008 Posts: 11
|
Posted: Sat Feb 09, 2008 7:55 am |
|
|
|
Here's the code so far:
Code:
<style type="text/css">
.one{
text-indent:80px;
font-style:normal;
}
.two{
text-indent:40px;
font-style:normal;
}
</style>
</head>
<body>
<p class="one">AL<br>
(Wakes) Why are you rocking my chair?
<p class="one">BOB<br>
Man, this chair really rocks.
<p class"two">(BOB pushes faster and faster.)<br>
======
The above code gives: (THE FORUM SCRIPT REMOVES THE INDENTS.)
(INDENTED) AL
(Wakes) Why are you rocking my chair?
(INDENTED) BOB
Man, this chair really rocks.
(NOT INDENTED) (BOB pushes faster and faster.)
The line (BOB pushes faster and faster.) is correct except that it should be
indented about 1/2 as much as the AL line, and it is not indented at all.
These are the only 2 indents that will be needed for the play, but they will
be used over and over again for these and other characters.
Regards, George
The css code is the entire code I am trying to use. |
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|
|
 |
|
|
|
|
|
|
|