First of all, feel free to skip to the end for the solution. Please leave a comment if this helped you in any way (or not).
My Dad recently bought a Mac and designed a website in iWeb. When it came to publish the site I configured it and hit “publish”. Up popped a message telling me that the site was now live at “<sitename>.com/site”. Mmm I thought, I must have made a mistake when configuring it. I went back and checked the settings and found in actual fact this is “just the way it works”
Rubbish!
I Googled the situation and found that using the only way people were getting around this issue was to upload their website in an FTP client like Cyberduck. All well and good, but hardly the most tidy solution.
I decided to go about this a different way, by telling the server that instead of looking in the “www” folder as the root of the site, it should instead look inside the “site” folder.
This was achieved by creating a “.htaccess” file inside “www” (or “public_html” as it may be). You need to edit the next bit to fit your site, but you get the idea:
RewriteEngine on
#
RewriteCond %{HTTP_HOST} yoursite\.com [NC]
RewriteCond %{REQUEST_URI} !/site
RewriteRule (.*) /site/$1 [L]
Note: make sure you keep the slashes the way they are, they look odd but they are needed.
This simply tells the server to look inside the iWeb created folder whenever anyone goes to your site. Set this up once and you should be able to forget about it from then on, it just works.
I hope this helps people resolve an issue that really should not be there in the first place. Please leave a comment with your thoughts.







Recent Comments