yes they are
Main Topics
Browse All TopicsHi All,
I'm using a shared hosting service and a shared ssl certificate. To keep it simple I have a page that just displays an image that looks like this:
<img src="/theme-images/42devlo
So when I use http://mydomain.com/tst.ht
Now when I use the shared ssl certificate which looks like this:
https://web87.secure-secur
it loads the page ok, but doesnt display the image.
Now this is no surprise as the ssl has added a new level, but the directory that contains tst.html also contains an .htaccess file that looks like this:
IfModule mod_ssl.c>
RewriteBase /42developments.net//
</IfModule>
<IfModule !mod_ssl.c>
</IfModule>
RewriteRule test index.html
RewriteRule ^$ index.htm
RewriteEngine On
RewriteRule ^([^.]*)$ index.cgi/$1 [L]
RewriteEngine On
RewriteRule ^([^.]*)$ index.cgi/$1 [L]
SetEnv DEFAULT_PHP_VERSION 5
Now as I understand it, the first three lines should move the base down a level if ssl is being used and allow the same code to work ok.
However, Im not an expert on this Apache stuff, but I know one of you guys is! J
Regards
Graham
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Nothing!
I'm pretty sure that is because it's not trying to load the images from my site, but it's issuing a url request such as:
https://web87.secure-secur
I can see this when I do an image properties in IE.
In other words, it's trying to load the image from a directory that doesn't exist at that level.
This is what I would expect to happen if the above RewriteBase were not in place, but it is!
> This is what I would expect to happen if the above RewriteBase were not in place, but it is!
mod_rewrite will not and cannot change your html source code.
If your html source looks like <img src="/theme-images/42devlo
Once you removed the leading slash (=it's now a relative path), the browser's request will depend upon the current level, i.e.
<img src="theme-images/42devlog
embedded in http://example.com/a.html will result in a request of http://example.com/theme-i
embedded in http://example.com/foo/a.h
embedded in http://example.com/foo/bar
etc.
Hi, thanks for your reply, sorry for the late response!
If rewriteBase doesnt er& change the base, then what on earth does it do?
I dont want it to change source code, just the base from which all urls are taken which is what I thought it did.
I cant use relative urls because I use an included file (a Javascript menu builder) which has url references inside it. I then use this file at different directory levels in my site and I obviously dont want to have multiple copies of the same file.
So, when I saw rewritebase, I thought that was exactly what I needed!
I might have to resort to buying an SSL certificate rather than using the shared one!
Regards
Graham
> just the base from which all urls are taken which is what I thought it did.
That's the server side. mod_rewrite doesn't parse html source code.
When a substitution occurred in directory context, RewriteBase substitutes the added directory prefix with the given base instead of stripping the documentRoot prefix. This (and the directive RewriteBase) is only necessary in Alias situations because stripping the documentRoot fails in that case.
A 3rd party module called mod_proxy_html can change the html source. http://apache.webthing.com
Business Accounts
Answer for Membership
by: ahoffmannPosted on 2008-04-11 at 03:22:03ID: 21332728
are your pictures in /42developments.net/theme- images/ directory?