Create a .ctp file from the static page, put it at
app/webroot/home.ctp and let PagesControler serve it up.

On Thu, Oct 8, 2009 at 4:09 AM, stefanski <stefansc...@googlemail.com> wrote:
>
> Does anybody know what to do, if the static html page should be the
> hompage of the site?
>
> There usually is by far the most traffic, so it would be great to have
> a static html  (which could be generated as well) that the webserver
> could send without having to initialize the cakephp framework.
>
> I guess ther needs to be som rewriterule ... ?
>
> Cheerio, Stefan
>
>
> On 29 Sep., 02:00, brian <bally.z...@gmail.com> wrote:
>> On Mon, Sep 28, 2009 at 10:56 AM, dong.l...@gmail.com
>>
>>
>>
>> <dong.l...@gmail.com> wrote:
>>
>> > Dear all,
>>
>> > I have existed html files for one website, I would like to intergrate
>> > them withcakephpto add some dynamic methods. At the same time, I
>> > want to keep all the oldstaticpages to save time. When I put html
>> > pages in the root folder, it still handle bycakephp. I know it
>> > because the .htaccess file will look for index.php file in the webroot
>> > folder first.
>>
>> > So how can I change the .htaccess file to make it work. I want it can
>> > look for .html files first, if no html files, then it looks for
>> > index.php.
>>
>> > Below is oringal .htaccess file
>>
>> > <IfModule mod_rewrite.c>
>> >   RewriteEngine on
>> >   RewriteRule    ^$ app/webroot/
>> >   RewriteRule    (.*) app/webroot/$1 [L]
>> > </IfModule>
>>
>> There's no need to change any of the .htaccess files. Put your HTML
>> files in app/webroot. The .htaccess file in that directory will only
>> pass the request to Cake if the file or directory does not exist
>> there. Note the 2 RewriteCond lines:
>>
>> <IfModule mod_rewrite.c>
>>     RewriteEngine On
>>     RewriteCond %{REQUEST_FILENAME} !-d
>>     RewriteCond %{REQUEST_FILENAME} !-f
>>     RewriteRule ^(.*)$ index.php?url=$1 [QSA,L]
>> </IfModule>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to