Re: Not found error with DEBUG 0

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: Not found error with DEBUG 0

luputski

I had the same problem (switching debug to 0 returned 404 where it
shouldn't) after moving some files between computers. Seemed to be some
permission issues so I just made sure everything in the app folder is
set to read/write and it works fine now.

On Oct 29, 12:49 pm, "MrTRAP" <[hidden email]> wrote:

> Hi everyone!
>
> I'm having some troubles in development with CakePHP. I've created a
> menu controller, view and model. When I set DEBUG > 0 in
> app/config/core.php I can access all my actions in menu controller
> without problems, but when I set DEUBG 0 I always get a 404 not found
> page:
>
> ---
> Not found
>
> The requested address was not found on this server.
> ---
>
> If I try to access a controller that doesn't exist, I get the message:
> The requested address <controllername + controlleraction> was not found
> on this server.
> If I change the $useTable in menu model to another table in my db, I
> can see the rendered action with no data, obviously.
>
> Does anyone know what could happening?
>
> Thanks!
> Luiz Carlos Junior.
>
> PS: sorry for my poor english :(


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

Reply | Threaded
Open this post in threaded view
|

Re: Not found error with DEBUG 0

luputski

I had the same problem (debug = 0 returning 404 where it shouldn't)
after moving some files between computers. Seemed like a permission
issue so I just made sure everything in the app folder is set to
read/write and it's fine now.


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

Reply | Threaded
Open this post in threaded view
|

Re: Not found error with DEBUG 0

Vanchuck

I think this has been posted in several threads before, but just in
case someone goes searching groups for this in the future, and the
above solution doesn't work...

Instead of setting permissions, try deleting the model cache files.
They'll be re-created next time around with the proper permissions
automatically (much lazier and easier). They're in
/app/tmp/cache/models . They aren't read from in DEBUG > 0, so that is
why it's only happening with DEBUG=0.

I think I also read once that if the database table changes, the cached
model file will of course be wrong, and it can cause similar or other
errors. The app/tmp/cache/models directory holds the results of the
"DESC" database queries, IIRC. If you have $persistModel = true; for
any of your models, then you might also have some problems if the
permissions are off in your /app/tmp/cache/persistent directory

I once accidentally checked in the model cache files in my versioning
software without realizing, so for a while, every time I did an update
of the project files I kept on getting this error, as the files were
being replaced with old and broken versions! Don't forget to exclude
that directory from your project if you are using version control
software (cvs/svn).


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

Reply | Threaded
Open this post in threaded view
|

Re: Not found error with DEBUG 0

MrTRAP

Wow! I was getting crazy! lol!
Thanks a lot! This solved my problem :)


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