Thank you for your reply Jeremy. Regarding the link, I already did that, and it works fine when you place the cake project at the root of where the domain points at. But if you want to place it in a sub-folder, it won't work, I tested it, even changing the "RewriteBase / " parameter with the appropiate path. So I guess something else needs to be done.
Regarding the Blog tutorial, I just deleted everything and did it again, and now works! So who knows... but I'm sure I only had one PostController, I strictly followed the tutorial... Well it's time to keep fighting with CakePHP, thank you! On Feb 3, 7:09 am, Jeremy Burns | Class Outfit <[email protected]> wrote: > See > herehttp://articles.classoutfit.com/2009/08/setting-up-cakephp-on-a-11-se...for > a tip on getting it to work on 1&1. > > Are you certain you don't already have a Posts controller? > > Jeremy Burns > Class Outfit > > [email protected]http://www.classoutfit.com > > On 3 Feb 2011, at 07:37, lebert wrote: > > > Hi! > > > I'm new to CakePHP, so I decided to download yesterday from the > > website the last stable version 1.3.7 from cakephp.org. > > > After struggling to set everything up in my 1&1 hosting, and realizing > > that it only works when installing it in the root of my domain, not in > > a subfolder (if anyone knows a link with an explanation of how to do > > that, it would be very helpful though) I decided to follow the Blog > > tutorial to get in touch with CakePHP. Well, I didn't get very far... > > > At the step "11.7.1 Create a Post controller" (http://book.cakephp.org/ > > view/1531/Cake-Database-Configuration#!/view/1535/Create-a-Posts- > > Controller), I get the following error when uploading the file created > > there: > > > Fatal error: Cannot redeclare class PostsController in /homepages/28/ > > d230065733/htdocs/cakePHP/app/controllers/posts_controller.php on > > line 15 > > > I've followed exactly what the tutorial says. I've actually started > > over to see if I had missed something, being super careful, but still > > the same error. This is how that file looks like: > > > <?php > > class PostsController extends AppController { > > var $helpers = array ('Html','Form'); > > var $name = 'Posts'; > > > function index() { > > $this->set('posts', $this->Post->find('all')); > > } > > } > > ?> > > > If I try the application before uploading this file, I get the obvious > > error that "PostController" does not exist, and asks me to create it. > > If I create it and upload the file (posts_controller.php) without the > > index() function, I get an error saying that "Action index is not > > defined", which is also normal. But when I include that fragment of > > code, then I get the fatal error I mentioned before, with all the > > display on white and the error message on black. > > > I've followed the tutorial line by line and I don't see any difference > > between my code and the tutorial. Another weird thing is that the > > fatal error says "on line 15", when the code has only 10... And by the > > way, when I installed and configured the CakePHP project, I got all > > the test things on green, so I don't think it's a configuration > > problem... > > > I'm super confused and frustrated, I want to learn CakePHP but it > > sucks to be struggling so early! Any help or advice would be much > > appreciated! I assume that the tutorial works, so I guess that I'm > > doing something wrong, but I have no clue what can it be... > > > Thanks so much in advance! > > > -- > > Our newest site for the community: CakePHP Video > > Tutorialshttp://tv.cakephp.org > > Check out the new CakePHP Questions sitehttp://ask.cakephp.organd help > > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > > [email protected] For more options, visit this group > > athttp://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php
