On Tue, Jan 20, 2009 at 4:39 PM, teknoid wrote:
>
> This is a simple solution, that I prefer.
>
> I ensure that all links to static pages point to .html file
>
> So our link:
> www.example.com/pages/about_us
>
> Becomes:
> www.example.com/about_us.html (i.e. echo $thml->link('About Us', '/
>
This is a simple solution, that I prefer.
I ensure that all links to static pages point to .html file
So our link:
www.example.com/pages/about_us
Becomes:
www.example.com/about_us.html (i.e. echo $thml->link('About Us', '/
about_us.html'); )
Then a single route takes care of the rest (for
Hi leo,
> And that is what it does. Go to http://univerd.com/mantenimiento-jardin
> . That is a pages page. Nothing is specifically defined for that page.
ok - but how!? the routes you provided do not have an asterix after
the first trailing slash, so how is cake getting the value from the
url
And that is what it does. Go to http://univerd.com/mantenimiento-jardin
. That is a pages page. Nothing is specifically defined for that page.
On Jan 20, 7:00 pm, "Jon Bennett" wrote:
> Hi Leo,
>
> > Router::connect('/pages/*', array('controller' => 'pages', 'action'
> > => 'display'));
>
> It
On Tue, Jan 20, 2009 at 4:00 PM, Jon Bennett wrote:
>
> Hi Leo,
>
> > Router::connect('/pages/*', array('controller' => 'pages', 'action'
> > => 'display'));
>
> It's the above route he's trying to avoid. He wants to have:
>
> Router::connect('/*', array('controller' => 'pages', 'action'=>
> 'd
Hi Leo,
> Router::connect('/pages/*', array('controller' => 'pages', 'action'
> => 'display'));
It's the above route he's trying to avoid. He wants to have:
Router::connect('/*', array('controller' => 'pages', 'action'=> 'display'));
but you can't do that unless you create a route for all yo
This fragment from PagesController::display() handles specific
actions:
<--snip-->
$path = func_get_args();
// Clumsy, but I couldn't find a better solutio in the time
available.
if(end($path) == 'SendEmail')
{
$this->SendEmail();
exit();
}
if(
I like all the suggestions you guys made. These are the suggestions I
was looking for!
I'll take these into consideration and work on it a little. I like the
idea of dropping things into bootstrap to automatically be run.
I'll put something up in the next couple days.
-Jesse
On Jan 19, 3:36 p
On Mon, Jan 19, 2009 at 7:21 PM, leo wrote:
>
> Ahh..you didn't say that. Seems to me all you need to do is put the
> pages in ..er.. pages and make sure that the pages route is last in
> the routes.php file. That way everything that has a home will find it
> and the rest falls through to pages.
Ahh..you didn't say that. Seems to me all you need to do is put the
pages in ..er.. pages and make sure that the pages route is last in
the routes.php file. That way everything that has a home will find it
and the rest falls through to pages. No lookup for page names needed.
You might even be able
hi Jesse,
> I was looking for a way to circumvent putting a "Router::connect"
> for each static page I have. Some of my sites have 100-150 static
> pages. I'm looking for a way to dynamically build the routes for all
> the pages.
>
> My script I wrote does work, I was just looking for in
hi Jesse,
> I was looking for a way to circumvent putting a "Router::connect"
> for each static page I have. Some of my sites have 100-150 static
> pages. I'm looking for a way to dynamically build the routes for all
> the pages.
>
> My script I wrote does work, I was just looking for in
On Mon, Jan 19, 2009 at 6:48 PM, leo wrote:
>
> Are your static pages html or PHP? Either way, why can't you just put
> them in webroot? They only need to be inside the cake structure if
> they're cake files.
>
That means I can't take advantage of the CakePHP helpers and such ...
besides, if the
Are your static pages html or PHP? Either way, why can't you just put
them in webroot? They only need to be inside the cake structure if
they're cake files.
Jesse wrote:
> I know this comes up a lot. I've always fixed this before (1.1) with a
> core hack. I thought that as I moved my sites to 1.2
On Mon, Jan 19, 2009 at 6:09 PM, Jesse wrote:
>
> Thanks both of you for your input.
>
> All my mod_rewrite stuff is working properly.
>
> I was looking for a way to circumvent putting a "Router::connect"
> for each static page I have. Some of my sites have 100-150 static
> pages. I'm looking
Thanks both of you for your input.
All my mod_rewrite stuff is working properly.
I was looking for a way to circumvent putting a "Router::connect"
for each static page I have. Some of my sites have 100-150 static
pages. I'm looking for a way to dynamically build the routes for all
the pages.
In addition to clarkphp's comment, if you have static files inside
directories, ie. views/pages/about/foo.ctp
Router::connect('/about', array('controller' => 'pages', 'action' =>
'display', 'about/index'));
Router::connect('/about/*', array('controller' => 'pages', 'action' =>
'display', 'about')
Jesse,
Are you wanting to access static pages without seeing the word "pages"
in the URL?
You could edit app/config/routes.php to have lines like this in it:
Router::connect('/about', array('controller' => 'pages', 'action' =>
'display', 'about'));
Router::connect('/join', array('controller' => '
I know this comes up a lot. I've always fixed this before (1.1) with a
core hack. I thought that as I moved my sites to 1.2 now I would come
up with a little better solution.
I'm not sure if this is the best solution but it works for me. I want
others thoughts and opinions for this solution.
THE
19 matches
Mail list logo