[SOLVED] I have to manually remove backslash - NEWS Module

For discussion and questions related to CMS Specific templates and stylesheets (CSS), and themes. or layout issues. This is not a place for generic "I don't know CSS issues"
Post Reply
User avatar
fearmydesign
Power Poster
Power Poster
Posts: 363
Joined: Sun Feb 28, 2010 10:54 pm

[SOLVED] I have to manually remove backslash - NEWS Module

Post by fearmydesign »

Hello, so I know how to fix this problem, but I don't understand why it happens. I also looked at this older thread that was kind of helpful, but its not clear to me why I could be having this issue with my NEWS module. http://forum.cmsmadesimple.org/viewtopi ... re#p273207

So I find that sometimes when creating templates, or a style sheet, I have to either add or remove the backslash from the path to whatever image in order for it to show
(i.e. /uploads/images/this.jpg) or (i.e. uploads/images/this.jpg)

But now, when I am adding news articles {news}, and if I add an image to the content, it will not show, so I have to uncheck the "Use WYSIWYG editor" and manually add a "/" before the uploads/images/etc... image path

...any ideas why this happens?
Last edited by fearmydesign on Fri Mar 30, 2012 9:30 pm, edited 1 time in total.
staartmees
Power Poster
Power Poster
Posts: 1049
Joined: Wed Mar 19, 2008 4:54 pm

Re: I have to manually remove backslash - NEWS Module - why?

Post by staartmees »

check your config.php and reduce it to only the required lines as described in doc/CMSMS_config_reference.pdf
User avatar
fearmydesign
Power Poster
Power Poster
Posts: 363
Joined: Sun Feb 28, 2010 10:54 pm

Re: I have to manually remove backslash - NEWS Module - why?

Post by fearmydesign »

staartmees wrote:check your config.php and reduce it to only the required lines as described in doc/CMSMS_config_reference.pdf
This is not my problem, my paths on the config file are setup correctly... maybe I was vague in my explanation.

When I add images to my pages, it works fine, it adds the image like this:

Code: Select all

<img src="uploads/images/etc....>
but when I add an image to the content on a {NEWS} article that I am writing, it adds the code the same *exact* way:

Code: Select all

<img src="uploads/images/etc....>
...but it doesn't show the image when I pull the article on the site to view. So what I have to end up doing, is going back to that same news article, and *add* a backslash before the uploads like this:

Code: Select all

<img src="/uploads/images/etc....>
So why doesn't this happen with all my other pages...? that's my question.

Thanks for your help
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: I have to manually remove backslash - NEWS Module - why?

Post by Dr.CSS »

You do have the {metadata} tag in the template, right?...
User avatar
fearmydesign
Power Poster
Power Poster
Posts: 363
Joined: Sun Feb 28, 2010 10:54 pm

Re: I have to manually remove backslash - NEWS Module - why?

Post by fearmydesign »

Dr.CSS wrote:You do have the {metadata} tag in the template, right?...
Actually not for my NEWS template. I am using the AutoPilot metatag creator here: http://www.i-do-this.com/blog/48/Put-yo ... -autopilot
So is this what's affecting it? not having the {metadata}?

Thank you
User avatar
fearmydesign
Power Poster
Power Poster
Posts: 363
Joined: Sun Feb 28, 2010 10:54 pm

Re: I have to manually remove backslash - NEWS Module - why?

Post by fearmydesign »

By the way, this is the page... the image is showing in the content right now because I added the "/" before uploads...
http://www.granitekitchencountertopsva. ... -rock.html
User avatar
Dr.CSS
Moderator
Moderator
Posts: 12711
Joined: Thu Mar 09, 2006 5:32 am

Re: I have to manually remove backslash - NEWS Module - why?

Post by Dr.CSS »

By default the {metadata} tag pulls the <base href=*********> into the head so it has a reference for things like images in pages allowing them to use relative URLs...
User avatar
fearmydesign
Power Poster
Power Poster
Posts: 363
Joined: Sun Feb 28, 2010 10:54 pm

Re: I have to manually remove backslash - NEWS Module - why?

Post by fearmydesign »

Dr.CSS wrote:By default the {metadata} tag pulls the <base href=*********> into the head so it has a reference for things like images in pages allowing them to use relative URLs...
Got it, thanks.
Post Reply

Return to “Layout and Design (CSS & HTML)”