UnitedForums - UK Web Hosting Forum UnitedHosting Community Hosting Forums
Network and Server StatusCustomer SupportUK Web Hosting
UnitedHostingUnitedHosting Sitemap UK Hosting ForumUK Web HostingWeb Hosting ForumsUK Reseller HostingWeb Host CommunityUK Managed Dedicated ServersHosting Help and SupportUK Domain Name Registration

Go Back   UnitedForums.co.uk > UnitedHosting Community > Website Applications

Reply
 
Thread Tools Rate Thread Display Modes
Old 10th May 2008, 11:40 AM   #1 (permalink)
lobstu
Registered User
 
Join Date: May 2008
Posts: 5
Arrow CakePHP Configuration Issue

I have managed to get my CakePHP site working on my account.

DB, Sendmail, all fine.

One last niggle though, is that the CakePHP folder structure is set up such that your webroot isn't the root of the project. I have to use .htaccess to rewrite from / to /webroot/. This works fine, except for paths to folders.

Eg:

- site.com/file.htm will silently find and return site.com's www/html/webroot/file.htm.
- site.com/folder/file.htm will silently find and return site.com's www/html/webroot/folder/file.htm.

Both of these work as intended. However

- site.com/folder will REDIRECT the browser to site.com/webroot/folder and then return the default document for site.com's www/html/webroot/folder/.

I don't want that to happen. I have things working on my development PC, I simply changed the DocumentRoot in my apache config to point to the webroot folder. Can UnitedHosting do this for my account?

The other alternative is that I place the contents of webroot/* into /var/www/html and then place the rest of the files in some other PHP-accessible location. I'm guessing this is the tougher of the two to do due to permissions and security and such.

Either way, I need to ensure that these redirects do not occur because I am migrating a site with indexed web pages eg. site.com/blog. and it'll cause all sorts of hell for me if I don't fix it.

My preferred solution is simply to change the DocumentRoot.

Thoughts guys?
lobstu is offline   Reply With Quote
Old 10th May 2008, 05:56 PM   #2 (permalink)
MrBen
Munky!
 
MrBen's Avatar
 
Join Date: Sep 2003
Location: nr Woking, England
Posts: 2,551
Quote:
Originally Posted by lobstu View Post
The other alternative is that I place the contents of webroot/* into /var/www/html and then place the rest of the files in some other PHP-accessible location. I'm guessing this is the tougher of the two to do due to permissions and security and such.
This is the way to go. You can either place the rest of the files/folders somewhere in /home/site_admin_username folder (PHP can access the site admin's personal area without issue) or have UH support create a folder for you in /var/www

Ben
__________________
The impossible I can do today, miracles take a little longer

Veterinary Practice Management System by SoftFooding
Internet Data Usage Calculator: Estimate your monthly bandwidth usage for your Internet connection.
Little Red: Nordic Style Rye Bread
MrBen is offline   Reply With Quote
Old 12th May 2008, 11:52 AM   #3 (permalink)
lobstu
Registered User
 
Join Date: May 2008
Posts: 5
Thanks Ben! I'll give that a try.
lobstu is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


All times are GMT. The time now is 12:07 PM.

UK Web Hosting  |  UK Reseller Hosting  |  UK Dedicated Servers UnitedHosting  |  UnitedSupport  |  UnitedForums  |  SEO by vBSEO 3.0.0
Copyright © 1998-2008 United Communications Limited. All Rights Reserved. Registered in England and Wales 3651923 - VAT Reg No. 737662309