i am saving the work in home page but it is not seen as the home page.some
static page is loading as the home page.i want the page which i am changin
as the home page.what should i do?
home page is : http://dev.example.al/example1
the page i want as home :
Hi,
I want my posts url to be like this:
example.com/post-slug
so I added the routing rule on routes.php like this
Router::connect('/*', array('controller' = 'posts', 'action' = 'view'));
It works well but other links give 404 error like this one
Error: The requested address
A few things come to my mind off the top off my head.
You could route your controller-action url's first, to catch the actual
links such as /members/users/login (is members a prefix, or do you have a
users method with login parameter, or do you have that as a custom route?)
Then providing you
Hi Stephen,
s members a prefix, or do you have a users method with login parameter, or
do you have that as a custom route?
Yes, members is a prefix but the problem also exists with urls without
prefix like /pages/display/about
I found a post on Mark Story's blog that is talking about my
The link you gave me is done a little differently to how you are doing it
now, all the post is introducing is a new method to parse the route itself.
Normally you may have something like /posts/view/slug which may be public
function view($slug = null), then you may execute a query to find the
But other links like /pages/display/about gave me 404 error as it routes to
posts controller not pages controller.
Thanks
On Friday, January 3, 2014 10:07:23 PM UTC+2, Stephen S wrote:
The link you gave me is done a little differently to how you are doing it
now, all the post is
Hey, that was just a test to see if those two routes were working, am I
right in assuming the members one worked and the posts one worked, but all
your others did not?
All you need to do is setup routes *before* the posts route to catch the
ones which are currently broken, you can specifically
Taking a plain CakePHP 2.0.5 (or minor) and installing it in a subdirectory
without mod_rewrite (removing the 3 .htaccess and uncommenting
Configure::write('App.baseUrl', env('SCRIPT_NAME')); in core.php) brings
up the following problem:
Loading the root page like this:
hi,
first of all: sorry for my englisch!
i would like realsies following url's:
www.domain.com
www.domain.com/somecategoriename/
www.domain.com/some-product-name.htm
So without show the controller and the view in the URL.
My current solution:
routes.php conf. for PageController:
hi,
first of all: sorry for my englisch!
i would like realsies following url's:
www.domain.com
www.domain.com/somecategoriename/
www.domain.com/some-produkt-name.htm
So without show the controller and the view in the URL.
My current solution:
routes.php conf. for PageController:
I'm building a blog plugin for CakePHP. It is called 'blog'.
I am following the manual on plugin routing but my links won't work.
http://book.cakephp.org/view/951/Plugin-routing
For example, when I am on this page: appname/blog/posts/index, I have
a link to the index action of the users plugin.
I have not found myself on that situation, but my guess is that by default
the controller name takes preference over the plugin name when the router is
parsing the URL (in other words: you cannot have a plugin with the same name
as a controller). I'm not sure if you could fix that by defining a
Your Html-link() is correct and should point to /users/users/index . Check
your routes.php, perhaps you are routing this to blog plugin.
--
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
I'm trying to translate my application, works fine but I have a
problem when changing the language,
mi default language is english, but also work with Spanish
this is my url has the lang tag.
http://localhost/caketra/articles/index/lang:eng
but my intention is to display in this way
no, i use the authsome component from debuggable...
On 28 Mai, 10:18, Bogdan Bursuc bogdanbursu...@gmail.com wrote:
Do you use the Auth component ?
On Fri, May 28, 2010 at 9:07 AM, cronet cro...@gmx.de wrote:
hm...
i solved my problem with the following route configuration:
hm...
i solved my problem with the following route configuration:
Router::connect('/aktivieren/*', array('controller' = 'users',
'action' = 'activate', 'admin'=null));
I don't know why cake behave this way, because in the manual there's a
note to user admin=false, not admin=null in the html
Do you use the Auth component ?
On Fri, May 28, 2010 at 9:07 AM, cronet cro...@gmx.de wrote:
hm...
i solved my problem with the following route configuration:
Router::connect('/aktivieren/*', array('controller' = 'users',
'action' = 'activate', 'admin'=null));
I don't know why cake
Hey,
i defined the following route:
Router::connect('/aktivieren/*', array('controller' = 'users',
'action' = 'activate', 'admin'=false));
But everytime when I try to access /aktivieren cake routes me to
admin_activatie...
Here ar some vars from pr($this)
[action] = admin_activate
You need to define the master route, also:
Router::connect('/aktivieren/', ...); That's the router you access when you
enter /aktivieren.
On Fri, May 28, 2010 at 2:05 AM, cronet cro...@gmx.de wrote:
Hey,
i defined the following route:
Router::connect('/aktivieren/*',
that does not solve the problem...
Router::connect('/aktivieren', array('controller' = 'users', 'action'
= 'activate', 'admin'=false, 'prefix'=false ));
Router::connect('/aktivieren/', array('controller' = 'users',
'action' = 'activate', 'admin'=false, 'prefix'=false ));
Try add rewrite base to your webroot .htacces:
RewriteBase /myproject
On Nov 9, 3:43 am, Peter Bowen prbo...@gmail.com wrote:
Hi,
I'm sure the routing is messed up somewhere and I'd appreciate some
help (8 hours of googling and experimenting and I'd be about ready to
tear my hair out if I
Thanks but it didn't help. I'm desperate enough to start looking at
Code Igniter :(
On Nov 9, 3:21 pm, Dr. Loboto drlob...@gmail.com wrote:
Try add rewrite base to your webroot .htacces:
RewriteBase /myproject
On Nov 9, 3:43 am, Peter Bowen prbo...@gmail.com wrote:
Hi,
I'm sure the
IfModule mod_rewrite.c
RewriteEngine on
RewriteBase /myproject
RewriteRule^$webroot/[L]
RewriteRule(.*) webroot/$1[L]
/IfModule
And don't forget to restart Apache after change of httpd.conf Also
make sure that you edit right httpd.conf (at least with
Hi,
I'm sure the routing is messed up somewhere and I'd appreciate some
help (8 hours of googling and experimenting and I'd be about ready to
tear my hair out if I wasn't already bald).
--setup--
I'm using Mac OSX with XAMPP for development. I've got the project in
a
ok this is driving me nuts now. basically if i put an underscore after
the parameter e.x :slug_
cake is expecting to find a match on 'slug_' not 'slug' as i want. if
i put an underscore before slug ex _:slug it works fine.
it appears underscore doesn't work as a variable delimiter.
On Aug 6,
well i didn't want to do it this way but
in my bootstrap:
define('SEO_SEPERATOR', '_');
now in my links:
$html-link('mylink', array('controller'='mycontroler',
'action'='myaction', 'sid'=$sid, 'slug'=$slug . SEO_SEPERATOR));
in my router
connect('/:slug:sid/*, etc etc')
this works for right
Router::connect(
'/:slug_:sid/*',
array('controller' = mycontroller, 'action' = 'index'),
array(
'pass'=array('sid', 'slug'),
'sid'='[0-9]+',
'slug'='[0-9a-z-]+',
)
);
On Aug 6, 2:29 am, JamesF usaexportexpe...@gmail.com wrote:
for some reason when i am
thanks for your help. i tested your regex for 'slug' and i still ran
in to the same problem. i actually tried that same matching pattern
before i posted this.
very similar issue
https://trac.cakephp.org/ticket/5737
On Aug 6, 5:13 am, Dr. Loboto drlob...@gmail.com wrote:
Router::connect(
i even tried this thinking i was clever
Router::connect(
'/:slug__:sid/*',
array('controller' = mycontroller, 'action' = 'index'),
array(
'pass'=array('sid', 'slug_'),
'sid'='[0-9]+',
'slug_'='[0-9a-z-]+',
)
);
which gave me
@brian
yes in that attempt i was trying to see how the router was parsing
underscores, in the first example slug was 'slug' and the route
was /:slug_:sid/
in the last example i was curious to try slug as 'slug_', with the
route as /:slug__:sid/ to see how the regex parsed.
basically whenever i
for some reason when i am putting an underscore directly after a named
argument in my route, it breaks.
doesn't work:
Router::connect('/:slug_:sid/*', array('controller' = mycontroller,
'action' = 'index'), array('pass'=array('sid', 'slug'),
'sid'='[0-9]+'));
if i put a dash or any other
I'm writing a facebook app and am having problems with my routing.
First off I changed App.base to point to my facebook canvas path:
Configure::write('App.base', '/my_app');
I did this so I could use $html-url() to construct my URLs in my
views. It works great except for one problem.
Hello group,
i'm fairly new to cake and now i'm facing a problem with routing.
I would like to route a request like /tasks/result.php?valid to /
tasks/result/valid.
So i was trying the following:
Router::connect(/tasks/result.php?valid, array('controller' =
'tasks', 'action' = 'result',
If you're using the Auth component with admin routing, you might want
to review this recent ticket to see if it applies to you:
https://trac.cakephp.org/ticket/4708
On May 20, 2:54 pm, Joel K. [EMAIL PROTECTED] wrote:
Hello,
I'm using admin routing for a personal site that I'm building:
Tim, Trac is emitting a 500 error right now. Would you mind posting a
synopsis? I'm also having problems with admin routing and wonder if
it's related.
On Wed, May 21, 2008 at 8:34 AM, Sliv (Tim MacAleese)
[EMAIL PROTECTED] wrote:
If you're using the Auth component with admin routing, you
Hello,
I'm using admin routing for a personal site that I'm building:
mrjoelkemp.com. Admin routing was working on the appropriate modules
(namely software and writing), however, oddly, it seems that over the
past week the routing has been failing on the writing module, but not
the software
I want to route www.example.com/admin to www.example.com/admin/foo/index
so I tried the following routes, none of which work..
$Route-connect('/admin/', array('controller' = 'foo', 'action'
= 'admin_index')) // gives me a Private Method in Controller error
$Route-connect('/admin/',
I too encountered this same issue, it turns out it needs an additional
parameter. Try this:
$Route-connect('/admin/', array('controller' = 'foo', 'action' =
'index', 'admin' = 1));
On Jan 11, 12:52 pm, Greg Baker [EMAIL PROTECTED] wrote:
I want to
Hey,
I upgraded from CakePHP 1.2alpha to 1.2pre-beta 1.
My admin routing stopped working:
My old routing is: (in routes.php)
Router::connect('/admin/', array('controller' = 'backend_home',
'action'= 'home', 'admin'=1));
core.php:
Configure::write('Routing.admin', 'admin');
inside the
On Nov 9, 9:46 am, phpjoy [EMAIL PROTECTED] wrote:
Hey,
I upgraded from CakePHP 1.2alpha to 1.2pre-beta 1.
My admin routing stopped working:
My old routing is: (in routes.php)
Router::connect('/admin/', array('controller' = 'backend_home',
'action'= 'home', 'admin'=1));
core.php:
i overlooked that one, thank you
On Nov 9, 1:20 pm, AD7six [EMAIL PROTECTED] wrote:
On Nov 9, 9:46 am, phpjoy [EMAIL PROTECTED] wrote:
Hey,
I upgraded from CakePHP 1.2alpha to 1.2pre-beta 1.
My admin routing stopped working:
My old routing is: (in routes.php)
well, just now, i will search group to this answer,
thanks a lot!
On Nov 9, 12:42 pm, phpjoy [EMAIL PROTECTED] wrote:
i overlooked that one, thank you
On Nov 9, 1:20 pm, AD7six [EMAIL PROTECTED] wrote:
On Nov 9, 9:46 am, phpjoy [EMAIL PROTECTED] wrote:
Hey,
I upgraded from CakePHP
What I really want is to make it looks like in del.icio.us
the format loooks like :
www.example.com/username/controller/parameter
and it could be
www.example.com/controller/parameter
can i check whether the username exist or not on bootstrap (using
database) ?
how to use model in bootstrap ...
I asked to create a uniqe url from my client, he want to have uniqe
url because he want to track their marketing plans.
for example:
www.xyz.com/google/document_title
www.xyz.com/yahoo/document_title
www.xyz.com/otherportal/document_title
www.xyz.com/directmarketing/document_title
Hi All,
I have routes.php configured with custom url :
Router::connect('/cat/*', array('controller' = 'users', 'action' = 'goto'));
But when I type http://localhost/cat/2100
it returns :
Hi,
I use pretty url for a project and all work fine on my server.
On my client server the index.php is not build in the url made by
cake.
Exemple :
$ajax-link('linkName, /myController/myAction/,array(update =
content),null,FALSE)
give
On Development server --
Hello,
I have upgraded cake to the latest stable and I have some problems
with routing.
I need to call a route that report a list of types.
myapp.org/artists/type1
myapp.org/artists/type3
myapp.org/artists/type6
and when i call view i need to see the single artist by id
$Route-connect('/artists/view/*', array('controller' = 'artists',
'action' = 'view', 'artists', 'Artists'));
$Route-connect('/artists/*', array('controller' = 'artists',
'action' = 'index', 'artists', 'Artists'));
Just found the bug :-)
seems that in the past releases calling
48 matches
Mail list logo