![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| ||||
| ||||
|
|
I wish to apply a color change (style?) to a portion of a table element. |
|
In the following code, I want to have the line: a href="http://zazoosh.com">** Race photos can be found at www.ZaZoosh.com **</a be a different color (green) than all the other table elements. |
|
Note that this table element appears in the middle of the table, and I want only this line to be green - how do I accomplish this? TIA |
|
tr td style="vertical-align:top;">October 24</td td><a href="http://results.active.com/pages/page.jsp?eventID= 1765035">41st Annual GoDaddy.com ® YMCA Half Marathon + Family 5K</a br a href="http://zazoosh.com">** Race photos can be found at www.ZaZoosh.com **</a /td /tr |
#3
| |||
| |||
|
|
I wish to apply a color change (style?) to a portion of a table element. Doing color changes in HTML is early 1990s fashion. Nowadays people use CSS (possibly together with JavaScript, for "dynamic" changes). In the following code, I want to have the line: a href="http://zazoosh.com">** Race photos can be found at www.ZaZoosh.com **</a be a different color (green) than all the other table elements. In HTML, you cannot. In HTML (which we discuss in this group), you can set the color of _all_ links in some states, but not the color of a specific link. Well, you could always play with <font color="...">...</font> inside or outside the link element, just to see how modern browsers treat such constructs that have no well-defined effect on rendering. Note that <a> is not a table element. If it happens to sit on a table, oops I mean in a cell in a table, that's coincidential. Note that this table element appears in the middle of the table, and I want only this line to be green - how do I accomplish this? TIA Assign a class to the <a> element and use CSS to set the colors for it. Beware that you can make it impossible to users to distinguish it as a link, and you may get crazy in trying to figure out suitable colors. See "Links Want To Be Links" (Google for it). tr td style="vertical-align:top;">October 24</td td><a href="http://results.active.com/pages/page.jsp?eventID= 1765035">41st Annual GoDaddy.com ® YMCA Half Marathon + Family 5K</a br a href="http://zazoosh.com">** Race photos can be found at www.ZaZoosh.com **</a /td /tr I'm not sure what you are trying to accomplish, but to _highlight_ a link, bolding or suitable background color or a border around might be better ideas than green color. Note that the use of "**" for highlighting is something that we should have abandoned when we were no longer confined to our cells (i.e. character cell browsers, aka. "teletype browsing"). More information (that I had hoped wasn't needed): this code (not |
#4
| |||
| |||
|
|
More information (that I had hoped wasn't needed): this code (not mine, btw, but I have to maintain it) |
|
is in a .php file and is linked to my site's main page. I wasn't sure if I could insert CSS into a .php file, nor where to do it. Yes, I am only trying to get the line to "stand out" from the many others that are displayed, because this information and link are new and special. The "green color" wasn't important - just an example of something different |
|
(I don't know how or where the basic colors are set in the .php file...). |
#5
| ||||
| ||||
|
|
More information (that I had hoped wasn't needed): this code (not mine, btw, but I have to maintain it) You mean you didn't originally create it, but now it is your code, to maintain. |
|
is in a .php file and is linked to my site's main page. I wasn't sure if I could insert CSS into a .php file, nor where to do it. Yes, I am only trying to get the line to "stand out" from the many others that are displayed, because this information and link are new and special. The "green color" wasn't important - just an example of something different You also didn't state if you want the entire cell to be "stand out" or just one of the two links. (I don't know how or where the basic colors are set in the .php file...). The answer is: it depends. Inline CSS: |
|
One link only: td a href="http://results.active.com/pages/page.jsp?eventID= 1765035">41st Annual GoDaddy.com ® YMCA Half Marathon + Family 5K</a br a style="background: green;"> href="http://zazoosh.com">Race photos can be found at www.ZaZoosh.com</a /td That works for now - thanks! |
|
Entire cell: td style-"background: green;" a href="http://results.active.com/pages/page.jsp?eventID= 1765035">41st Annual GoDaddy.com ® YMCA Half Marathon + Family 5K</a br a href="http://zazoosh.com">Race photos can be found at www.ZaZoosh.com</a /td But if it was me, I'd tell you to look up CSS style sheets, and use a class in whichever place you wanted to "stand out." td class="standout" a href="http://results.active.com/pages/page.jsp?eventID= 1765035">41st Annual GoDaddy.com ® YMCA Half Marathon + Family 5K</a br a href="http://zazoosh.com">Race photos can be found at www.ZaZoosh.com</a |
#6
| |||
| |||
|
|
That works for now - thanks! |
#7
| |||
| |||
|
|
CSS is easy, once you are able to wrap your neurons around the concept. |
#8
| |||
| |||
|
|
In article <hc7rv3$7rm$1 (AT) news (DOT) eternal-september.org>, "Beauregard T. Shagnasty" <a.nony.mous (AT) example (DOT) invalid> wrote: CSS is easy, once you are able to wrap your neurons around the concept. Unlike, say, Quantum Physics. |
#9
| |||
| |||
|
|
dorayme wrote: "Beauregard T. Shagnasty" wrote: CSS is easy, once you are able to wrap your neurons around the concept. Unlike, say, Quantum Physics. Yup, that's neutrons. |
#10
| |||
| |||
|
|
* *I wish to apply a color change (style?) to a portion of a table element. *In the following code, I want to have the line: a href="http://zazoosh.com">** Race photos can be found atwww.ZaZoosh.com**</a be a different color (green) than all the other table elements. * |
![]() |
| Thread Tools | |
| Display Modes | |
| |