Ok, I narrowed it done to this line: ${$class} =& new $class
($settings); inside class_registry.php. I think it is failing when it
tries to load the class for the model, as we thought. Now I have to
try figure out why.Oh, and brian, I appreciate the response. That
controller I posted above is literally the only thing that has been
added to the app, considering I am trying to figure out why this thing
is going crazy. I appreciate your help.On Aug 18, 2:31 pm, brian <[email protected]> wrote: > I don't think it's the Cake files. I don't have any idea what it might > be. My point is that you need to find out where your app is croaking. > It *seems* to be related to the controller loading the models, so that > would be a good place to start. Otherwise, I doubt you're going to get > any other clues from the list as you haven't posted any code. > > On Tue, Aug 18, 2009 at 2:13 PM, Rich<[email protected]> wrote: > > > I'll try, but remember that this application is working on my local > > development server. I can pull it up and us it just fine. The one > > that is not working is on a Debian Linux, while the one that works is > > on a Windows WAMP install. I highly doubt cake's libraries are broken, > > but I will try. > > > On Aug 18, 1:59 pm, brian <[email protected]> wrote: > >> This is why I suggested debugging what's happening in loadModel(). > >> Have a look at Controller (in cake/libs) to see what's happening when > >> it's first instantiated. One of the things that happens is that the > >> $uses array is checked for models and those are loaded. Put some > >> debugging lines in there to log what's happening. Eventually, you'll > >> narrow it down somewhat. > > >> On Tue, Aug 18, 2009 at 1:36 PM, Rich<[email protected]> wrote: > > >> > Ok, for example sake, I created a test controller, and what do you > >> > know, it does exactly the same thing as my other controller. Now I > >> > purposefully left out a model and view, just so I know that I am > >> > getting a true blank page. There should be all kinds of Cake Errors, > >> > but all I get is a blank page. Here is the contorller: > >> > <code> > >> > <?php > > >> > class TesterController extends AppController > >> > { > >> > var $name = 'Tester'; > > >> > var $uses = array( > >> > 'TestModel' > >> > ); > >> > } > >> > ?> > >> > </code> > > >> > If you go to this controller in my fresh, brand new app, you get a > >> > blank page. If you comment out one line, the 'TestModel' line > >> > (rendering you an empty model array), it works. It doesn't matter what > >> > name you give it, if the array has something in it, it comes back with > >> > a blank page. Keep in mind there is not actually a model or view, so > >> > there should be an error saying so, but there isn't.The only way I > >> > have found to get something on the page besides not using a model, is > >> > by erroring out php, IE causing PHP to have an error. Typing jibberish > >> > in the middle of the file, or missing a semi-colon, or something like > >> > that. As you see, this is a basic controller, and I have added nothing > >> > else, the rest is a fresh cake install. > > >> > I have also tried various DB configs, with no change. No matter what I > >> > do, I seem to get a blank page. I also can't do a Try-Catch or debug > >> > simply because this is not happening inside a function, and PHP > >> > doesn't allow you to use things like that outside functions. Hope this > >> > helps describe the issue. > > >> > On Aug 18, 12:16 pm, brian <[email protected]> wrote: > >> >> I'd make a backup of cake/libs/controller/controller.php then have a > >> >> good look at loadModel(). Set debug = 2 and add some Debugger::log() > >> >> statements here and there. > > >> >> Might you have a forgotten die() statement anywhere in your own code? > > >> >> On Tue, Aug 18, 2009 at 9:20 AM, Rich<[email protected]> wrote: > > >> >> > Ok, this is going to be a long post, so let me begin at when this all > >> >> > started. This is a project for work, and what it essentially does is > >> >> > generate reports using Cake and a PDF generator. Now, it is ready to > >> >> > go live, and to get all that started we moved it to a dev server to > >> >> > test it before we put it fully live. I had been developing the app on > >> >> > my PC using WAMP for a while, inside a windows environment. The app > >> >> > moved from my local development platform of WAMP on windows to a Linux > >> >> > development server the company has. > > >> >> > As with any application, it never goes the way you want, but this time > >> >> > is was completely weird what happened. After gettting all the basics > >> >> > such as Mod Rewrite and whatnot to work, I noticed something. All you > >> >> > every get was a blank page. Nothing, no body, no head, nothing. Like > >> >> > any good developer, I checked all the logs. There are no errors in the > >> >> > php log, no apache errors, not even anything out of the ordinary in > >> >> > the Apache access log (typical mod rewrite access stuff was there). > > >> >> > So, I decided to go through my code, and I began commenting things > >> >> > out. The problem seemed to disappear if I commented out the $uses > >> >> > array, giving you basically: $uses = array(); Immediately, it became > >> >> > clear that something was wrong with one of my models. I commented out > >> >> > the model names in the $uses array one by one, and they all seemed to > >> >> > give me a blank page. It is crazy how you can comment out the models > >> >> > in your app and everything seems to work. No matter what model you > >> >> > use, they all cause a completely blank page. Just to be sure, however, > >> >> > I keep one model on and cleared out its contents, given me a blank > >> >> > model, it still gave me a blank page. > > >> >> > I have spent the better part of a week trying to fix this issue, > >> >> > spending most of that time trying various "blank page" fixes around > >> >> > the internet, both php and cakephp solution. Here are just some of the > >> >> > solutions I tried: > > >> >> > -Deleted all the App Cahce in the Cake App Cache Folder > >> >> > -Checked every file for space after the PHP tags > >> >> > -Checked all the logs for errors: PHP, Cake, and Apache show nothing > >> >> > - Tried CakePHP Testing, Didn't really work that well, or help me find > >> >> > an issue > >> >> > -Looked at Blank page tickets over at the CakePHP Trac and This google > >> >> > group > >> >> > -Searched Google for Blank Page solutions, went through pages upon > >> >> > pages with no solution > > >> >> > Now, keep in mind that I can get my app to show up as long as I don't > >> >> > use any models. As soon as I include a model with the $uses array, I > >> >> > get a blank page. It was suggested that it was linux being pick about > >> >> > case sensitive files names, but if that was the case, then it would > >> >> > never work. > > >> >> > I am also aware of using PDF generaters can cause blank pages, and > >> >> > trust me, I know what and when to expect such a PDF error. I have been > >> >> > working on this app for a couple of months, and with Cake longer than > >> >> > that. This is something I have never seen before, and something I > >> >> > can't seem to find anyone else having an issue with. The only time I > >> >> > have ever seen a blank page like this is with Wordpress, and typically > >> >> > that was because I had a space after the closing PHP tag. > > >> >> > I wish I could show you some code, but being a work project, I don't > >> >> > know how much I can show. Hopefully these descriptions help you. The > >> >> > strangest thing is that I can type random gibberish in most of my > >> >> > files and get a php error, indicating that php is still working. I > >> >> > really stuck right now, so any suggestions would help a lot. I am not > >> >> > a cake expert, but I am quite experienced in php and the web. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
