Hi,
Have just generated a new yii webapp, and after the config changes, next thing I am trying to do is change a bit of the look-n-feel.
Want to have a company logo (currently, just a 120x80 color-burst .png file) placed on the page header area, and I’ve tried couple of things like directly embedded <img> html tag, like this…
<div class="container" id="page">
<div id="header">
<div id="logo"><img url="myappweb/images/colorbox.png" alt="Color logo" /></div>
to, an invocation like this…
<div class="container" id="page">
<div id="header">
<div id="logo"><?php echo CHtml::image('myappweb/images/colorbox.png','Color logo'); ?></div>
and also tried with relative path like:
‘../../images/colorbox.png’
Situation is that with the CHtml::image() approach, the header area is empty, but with direct <img> tag approach, I get the alt text displayed, but not the image.
The browser ‘view source’ tells me that the HTML generation is fine, and the <img> line shows up in the correct place. Also directly accessing the image file in browser at http://localhost:8080/myappweb/images/colorbox.png works well. So my suspicion is around the site CSS, but not sure.
Can someone help me figure what’s going on ? I had enabled the
array(
'class'=>'CWebLogRoute',
),
config element, but I didn’t see any relevant log message that might indicate any problem. Is there some other approach I must adopt in debugging this ?
cheers,
Jay