Just in case you are confused... even by the documentation...
The Html Helper only creates HTML. So if you use the image() method, it
will output the actual img tag with all the attributes.
The src is going to use the path to the image that you specify, and with
cake the webroot folder is where /your/relative/path will default to.
So, you have stored your image in the
{app}/{webroot}/img/blogtest/image.jpg... that is what you use in your src
attribute, if you are creating the HTML by hand. (<img
src="/img/blogtest/image.jpg" />)
The PHP code will be <?php echo
$this->Html->image('blogtest/image.jpg',array('rel'=>'your_rel','id'=>'your_id'));
?>
This will output <img src="/img/blogtest/image.jpg" rel="your_rel"
id="your_id" />
There is no real funny business here, it's just a helper. But it does
default to the /img folder, unless you specify a full http://address.
Happy Coding!
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with their CakePHP related questions.
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php