|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
switch works on localhost, not webhost...
switch works on localhost, not webhost...
switch works on localhost, not webhost... Hello all. I have problem with switch statement in version PHP 4.2.2 on linux server. My error page is not coming (which used switch) instead i am getting the code of the entire page ....which is working perfectly on windows 2000. pls help thanx in advance ckb pls check part of my code: <?php // these code used to diplay message if there is any Unathiora include("connection.php"); // $ec=$_GET['ec']; //switch($ec) if(isset($_GET['ec']) ) { switch($_GET['ec']) { case 0: $message="<font color='black'><b> Your user name or password is incorrect! <a href=index.php>Please try again.</a></b></font>"; break; case 1: $message="<font color='darkgreen'><b> There was an authentication error. Please<a href=index.php>Log in </a>correctly.</b>"; } } ?> |
|
#2
|
||||
|
||||
|
If you're seeing PHP code, then your host does not have PHP installed correctly.
---John Holmes... |
|
#3
|
|||
|
|||
|
hi all..
now i am not geting the code of the page..... in my error page i am not getting the value of error code ec passed which is working perfectly on windows 2000. That means echo $_GET['ec']; is empty .... in the url i am getting the value of ec as 0... like this http://191.5.2.23/admin/ERROR.PHP?ec=0 .the main problem is i am not getting the value of $_GET['ec'] in the error page. pls help thanx in advance ckb |
|
#4
|
|||
|
|||
|
hi all,
now it's working fine......it was php version 4.2.2 only and my code also was correct....but a small mistake....i saved my file as ERROR.PHP IT WAS THE CAUSE OF MY PBM.....since it was linux it is not recognising my php file at all when i saved in capital letter....now everything i s ok..... thanx a ot for all.... ckb |
![]() |
| Viewing: Dev Shed Forums > Other > Dev Shed Lounge > switch works on localhost, not webhost... |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|