The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Script on only part of the page?

2 posters

Go down

Solved Script on only part of the page?

Post by Honor July 19th 2010, 3:15 pm

Hey all. I'm working on the double-forum thingy (where you create one forum to look like two - see my test site ).

This is what I have in that Orbit category.

Code:
<STYLE TYPE="text/css">
a:link { color: #003CFF; text-decoration: none }
a:active { color: #003CFF; text-decoration: none }
a:visited { color: #003CFF; text-decoration: none }
a:hover { color: #00FF22; text-decoration: underline }
</STYLE>
<STYLE TYPE="text/css">
<!--
BODY
  {
  text-align:justify;
  }
-->
</STYLE>


<center><font size="3" color="yellow"><b>BP Orbiting Station</b></font></center><br>

<table width="100%" border="0" cellspacing="2" cellpadding="2">
      <tr>
        <td width="284"><center><a href="http://blueplanet.road2us.com/world-f1/"><font size="2">World</font></a></center>
<br>Welcome to our world! This is the place for all people to hang out. Start a mini game, share a video or song, get creative and show us what your made of! This is the starting point of all visitors to BP.<br><br><br>
<font color=orange><u>Also:</u></font><br>
<a href="http://blueplanet.road2us.com/game-play-applications-f52/" title="Before you can RP, you must post an application of intent. Upon acceptance you then must post a character. When that character is approved you are free to roam, my friend!">Gameplay Applications</a><br>
<a href="http://blueplanet.road2us.com/writings-renderings-f51/" title="Where all stories related or non-related to the RP go. Multiple Blogs contained within this forum. If you have a multi-chapter story you want posted up, pm Honor to receive your own personal blog to moderate! There is a single blog for all short stories to go into - this one is a community blog and moderated by the admins. We can also do Art, Photography, or any thing else you want a whole blog to yourself for.">Creative Suite</a></td>

        <td width="31"></td>
        <td width="279"><center><a href="http://blueplanet.road2us.com/field-hq-lounge-f2/"><font size="2">Security Clearance</font></a></center>
<br>This is for all things meant just for our community's eyes. Tell us what's going on, start a side game, or just loosen your tie around here away from prying eyes. Some general paperwork may need attention.
<br><span style="color: aqua;">Member access only</span><br><br>
<font color=orange><u>Also:</u></font><br>
<a href="http://blueplanet.road2us.com/leaves-of-absence-f12/" title="Ask for time off here, or let us know that you can't post for more than 48 hours at a time. Real life always comes first - it just helps us to know when something sneaks up to steal your RP time.">Leaves of Absence</a><br>
<a href="http://blueplanet.road2us.com/archive-f13/" title="All things of the past.">Archive</a>
</td>
</td>
    </table>
<br>

<center><a href="http://blueplanet.road2us.com/journals-f14/">Character Journals</a><br>
Glimpses inside the characters of all worlds.
<br><span style="color: Red;">Do not use as common knowledge! </span></center>

But it's now affecting every forum that I place or create under it on the index. How do I end that justification code so that it's only in this one instance, and not on the index over all? I've tried adding a counter

<STYLE TYPE="text/css">
<!--
BODY
{
text-align:left;
}
-->
</STYLE>

on the forums under that one, but the alignment turned back to the left on it as well, even though the justification style is still there. Is there a way to justify what is in the table without using a style script? Something with an end tag that won't affect my whole document?
avatar
Honor
Forumember

Female Posts : 172
Reputation : 17
Language : English
Location : Bouncing off the Walls

http://blueplanet.road2us.com

Back to top Go down

Solved Re: Script on only part of the page?

Post by RoNo July 20th 2010, 12:02 am

Hello Honer, style and script are separate elements, this is actually about style.

There are 2 </td>'s at the bottom of your code. Close with </tr></table>


You can style an individual table (or div) with a class selector.

Example: .index2 has been added to the css,
class="index2" has been added to the table
Code:
<style type="text/css">
.index2 a:link { color: #003CFF; text-decoration: none; }
.index2 a:active { color: #003CFF; text-decoration: none; }
.index2 a:visited { color: #003CFF; text-decoration: none; }
.index2 a:hover { color: #00FF22; text-decoration: underline; }
.index2 { text-align:justify; }
</style>
<center><font size="3" color="yellow"><b>BP Orbiting Station</b></font></center><br>

<table class="index2" width="100%" border="0" cellspacing="2" cellpadding="2">
      <tr>
        <td width="284"><center><a href="http://blueplanet.road2us.com/world-f1/"><font size="2">World</font></a></center>
<br>Welcome to our world! This is the place for all people to hang out. Start a mini game, share a video or song, get creative and show us what your made of! This is the starting point of all visitors to BP.<br><br><br>
<font color=orange><u>Also:</u></font><br>
<a href="http://blueplanet.road2us.com/game-play-applications-f52/" title="Before you can RP, you must post an application of intent. Upon acceptance you then must post a character. When that character is approved you are free to roam, my friend!">Gameplay Applications</a><br>
<a href="http://blueplanet.road2us.com/writings-renderings-f51/" title="Where all stories related or non-related to the RP go. Multiple Blogs contained within this forum. If you have a multi-chapter story you want posted up, pm Honor to receive your own personal blog to moderate! There is a single blog for all short stories to go into - this one is a community blog and moderated by the admins. We can also do Art, Photography, or any thing else you want a whole blog to yourself for.">Creative Suite</a></td>

        <td width="31"></td>
        <td width="279"><center><a href="http://blueplanet.road2us.com/field-hq-lounge-f2/"><font size="2">Security Clearance</font></a></center>
<br>This is for all things meant just for our community's eyes. Tell us what's going on, start a side game, or just loosen your tie around here away from prying eyes. Some general paperwork may need attention.
<br><span style="color: aqua;">Member access only</span><br><br>
<font color=orange><u>Also:</u></font><br>
<a href="http://blueplanet.road2us.com/leaves-of-absence-f12/" title="Ask for time off here, or let us know that you can't post for more than 48 hours at a time. Real life always comes first - it just helps us to know when something sneaks up to steal your RP time.">Leaves of Absence</a><br>
<a href="http://blueplanet.road2us.com/archive-f13/" title="All things of the past.">Archive</a>
</td>
</tr>
    </table>
<br>

<center><a href="http://blueplanet.road2us.com/journals-f14/">Character Journals</a><br>
Glimpses inside the characters of all worlds.
<br><span style="color: Red;">Do not use as common knowledge! </span></center>
Apply styling to additional content with new classes: .index3 etc.
RoNo
RoNo
Active Poster

Male Posts : 1270
Reputation : 135
Language : English
Location : Laguna Beach, California

http://bf2mercenaries.forumotion.com/

Back to top Go down

Solved Re: Script on only part of the page?

Post by Honor July 21st 2010, 11:39 pm

Solved!
avatar
Honor
Forumember

Female Posts : 172
Reputation : 17
Language : English
Location : Bouncing off the Walls

http://blueplanet.road2us.com

Back to top Go down

Solved Re: Script on only part of the page?

Post by RoNo July 22nd 2010, 12:00 am

RoNo
RoNo
Active Poster

Male Posts : 1270
Reputation : 135
Language : English
Location : Laguna Beach, California

http://bf2mercenaries.forumotion.com/

Back to top Go down

Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum