Solved

Cake Routes Not Working in Version 1.2?

Posted on 2009-07-06
2
465 Views
Last Modified: 2013-11-24
Experts I'm having a problem with routing in Cake PHP here's the scoop:
Sorry but the links below don't show as  I had to put the site back to an operational state.
When I put in the URL: http://www.beatlesarama.com/songs/index/
The page comes up perfectly.

I want this page to display as my index page.

I created the route as follows:

Router::connect('/', array('controller' => 'songs', 'action' => 'display', 'index'));

When set this way it doesn't give any erros but the page does not show. The default.ctp shows but the content that is supposed to show does not.

if you go to the site as http://www.beatlesarama.com you will see what I mean.

Thanks in advance for your expert advice.

0
Comment
Question by:barnent1
2 Comments
 
LVL 3

Accepted Solution

by:
Siridivi earned 500 total points
ID: 24799923
It's been a while since I've done CakePHP programming, but I think you need this:

Router::connect('/', array('controller' => 'songs', 'action' => 'index'));
0
 
LVL 1

Author Closing Comment

by:barnent1
ID: 31600340
Thanks that wss exactly it. After reviewing the documentation I was trying to call a controller function that did not exist.

Thanks for the help..
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question