Re: help out a noob w/ include & switch?

From: Date: Tue, 20 Sep 2005 23:41:01 +0000
Subject: Re: help out a noob w/ include & switch?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-222825@lists.php.net to get a copy of this message
Thanks Thorsten and Rob, Sry my bogus code was error filled. This is not the case with the actual code. I was a little quick in removing the large amounts of text that are actually contained in the cases and "case 1,2,3:" is just to say there are many more cases. Could this be a problem - Is the server trying to return the values with $_GET to the browser? I assume the text from the content.php and navigation.php would be inserted on the server but I don't really know. In your suggestion, Thorsten, I actually used case "artist1" rather than case 'artist1'. I switched to single quotes and there is no difference. To the .ini settings suggested by both, I don't know what to do. If the problem is with a server setting, I have to know what it is to tell my server admin to change. He's not familiar with PHP as he uses CFM. He has a PHP server running just in case someone asked for it. I am the first. From phpinfo() I have found these two settings: "include_path .;C:\PHP\pear" for local and master; and "error_reporting" is 341 for local and master. I don't know if these are correct or how I should code my site to fit within them. Thanks again!! jt On September 20, 2005 11:14 pm, you wrote: > > Hi All, > > My very first post to this group as I'm a freshly spanked new born > > php > > baby. Hope I have the correct stop for noob tech questions. > > Welcome :) > > > [source] > > First guess: On your "live" server the ini-value error_reporting is > switched to report anything but notices and warnings or even completely > turned off. Second guess: in the switch statement you provided us as the > bogus code-fragment you did really forget to use > ' > > so you should try > > case 'artist1': > ... > > instead of > > case artist1: > > and, for integer values, use > > case 1: > case 2: > case 3: > ... > > instead of > > case 1,2,3: > ... > > > I hope this was valuable, or, in other words: HTH > > Best regards > > Thorsten

« previous php.general (#222825) next »