Change Text Color Based On Value
-
Hello,
I’m trying to change the “Link Large Description” text color based on value.
If value = “No” then color = red
If value = “Yes” then color = greenI’ve been searching for a HTML / CSS / PHP solution for this and am trying to use;
link-library/stylesheettemplate.css:
var content = $(".content p").text(); if (content == "Hay?r") { $(this).css("color", "#ffffff"); } if (content == "Evet") { $(this).css("color", "#ccc"); }
Library settings:
Before “Link Large Description”;
<b>Membership: </b><div class='content'>
Afer “Link Large Description”;
</div>
but it’s not working, any suggestions, help, replies are greatly appreciated and thank you all in advance.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Change Text Color Based On Value’ is closed to new replies.