Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8153981
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T16:11:39+00:00 2026-06-06T16:11:39+00:00

Currently this code generates a colored hyperlink to an ad listing on my site.

  • 0

Currently this code generates a colored hyperlink to an ad listing on my site. The problem is that the text is BLACK when viewing in Firefox and Chrome. It only seems to display the colored text in IE.

Can anyone please help me to make this work properly?

<a href="<?=ProdURL($rslt["offer_adsid"])?>" style="font-size:13px;"<?=$trColor?> ><?=$Lname?></a>

update:

here’s the HTML being generated. THANKS!

<a href="116-iphone-3g-8gb-as-is.htm" style="font-size:13px;"style="color:#FF0000;" >iPhone 3G 8GB AS IS</a

FIX!

I was able to fix this by finding where the value of $trColor is defined, then adding the font size style tag to be included along with the color style tag. Fixed now, thanks guys!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T16:11:41+00:00Added an answer on June 6, 2026 at 4:11 pm

    Thanks for giving the exact HTML output. I see two potential problems:

    1. There is no space before the second style= element. I’m guessing IE interprets this okay anyway, and the other browsers treat it as garbage and ignore it.

    2. I’m not sure if there’s an agreed-upon standard among the different mainline browsers of what to do when there are multiple style="..." attributes on a single HTML element. I haven’t tried it, but immediate questions that come to my mind are: Should they be additive? Or should one of them overrule the other one? I’ve always known the “correct” method to be combining all CSS directives into one style="..." attribute, which you could easily do here.

    I would make $trColor be just the hexadecimal color code, and rewrite the HTML like this:

    style="font-size:13px;color:<?php echo $trColor ?>"
    

    So that your HTML is rendered like so:

    <a href="116-iphone-3g-8gb-as-is.htm" style="font-size:13px;color:#FF0000">iPhone 3G 8GB AS IS</a>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

There is currently this Prototype code that does a PUT: new Ajax.Request(someUrl, { method:
I have some code that continuously generates UIImage frames for animation. Currently I am
I currently have this code which stores XML into an XML-type column called data,
I currently have this code: PACKETS = {}; function AddPacket(data) local id = data.ID;
I currently have this code : Private Sub Worksheet_Change(ByVal Target As Range) Dim lastrow
I currently have this code Private Sub Worksheet_Change(ByVal Target As Range) WorksheetChanged(Target, Range(AB3).CurrentRegion, Range(B18:B19))
I currently have this code which reads the first field in a database record
I'm currently using this code (per the codex) to show children on parent pages,
I'm currently using this code to calculate the sunrise / sunset times. (To be
I am currently using this code to grab key-strokes, but I am missing e.g.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.