CodeIgniter Forums

Full Version: Linking Question
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

El Forum

Hi everyone!

I need to know how to code this in CI:
<a href='customer.php'><img src='cust.jpg'></a>

from what I understood in the user guide, it is:

echo link_tag('customer.php'); echo img('cust.jpg');

is this right?

what about the </a> at the end?

im so confused

please help

ps: the user guide does not mention what to do about the </a>, nor how to link using an image.

El Forum

Erm. The link tag produces a 'link' tag.

Quote:Lets you create HTML &lt;link /&gt; tags. This is useful for stylesheet links, as well as other links.

It has nothing to do with anchor tags.

El Forum

it should be something like

echo anchor('test', img('images/test.gif'));