Page 1 of 1

(Solved) Page options: image (renders without image)

Posted: Wed Mar 04, 2009 8:37 am
by Oskar Rough
Hi,

I'm using 1.5.3. and wanted to try the image option that every page has. It works just fine, when I choose a picture but when I've got a page that shouldn't have a picture CMSMS adds the following line of code anyway:



In Firefox and Safari this isn't the biggest of problems, however, IE adds that annoying red-cross-icon. I guess it's a bug that should be fixed anyway :-)

Please, do ask if you have any questions.

Solved. Check third post.

Re: Page options: image (renders without image)

Posted: Fri Mar 06, 2009 6:02 am
by Dr.CSS
Works fine because you use it how?...

That kind of info works wonders in getting an answer to questions...

Like you could do an if there is an image show it if not don't do this etc. etc....

Re: Page options: image (renders without image)

Posted: Tue Mar 10, 2009 11:27 am
by Oskar Rough
Hey Mark! Thanks for the answer.

I managed to solve it using the following piece of code. If there's a better (more proper?) way of doing, let me know.

Code: Select all

{ assign var="fileToCheck" value=$content_obj->GetPropertyValue('image') } 
			
{ if $fileToCheck <> "-1" }			
	<img alt="" src="/uploads/images/{$content_obj->GetPropertyValue('image')}" />
{ /if }