URL with css |
[eluser]patsm[/eluser]
I'm new to Code Igniter and have a question that should be simple. I'm using CSS and all my <a> tags are a certain color. However, I want one section of my page to have a different color <a> links. In my stylesheet, I have the style defined as a.bLink, a.bLink:active, a.bLink:visited { font-family:tahoma; font-size:11px; text-decoration:none; color:#0099ff; } In my view I have this anchor link <?=anchor("classifieds/browse/category/{$categories[$x]['id']}","({$categories[$x]['itemcount']}) {$categories[$x]['category']}");?> How can I add this css style to this link? I would like it to display something like this... <a href="www.domain.com" class="bLink">Here is my link </a> I know this is something simple. Any help is greatly appreciated.
[eluser]Sumon[/eluser]
Try Code: <?php echo anchor("www.domain.com" , "Here is my link" , 'class="bLink"');?>
[eluser]lukeinjax[/eluser]
You can pass an array of attributes - http://ellislab.com/codeigniter/user-gui...elper.html Code: echo anchor('www.domain.com', 'My Domain', array('class' => 'bLink', 'title' => 'my title')); |
Welcome Guest, Not a member yet? Register Sign In |