Dethman Posted July 22, 2008 Share Posted July 22, 2008 Hey guys I got this error dont know why.... Parse error: syntax error, unexpected T_ELSE in /home2/psionic/public_html/vault.php on line 47 This is the PHP I have commented the Line 47: if($_POST['bank_action']){ $vault_tax=0.8; $amt=floor($_POST['amountB']); $amt_minus_tax=($amt-$vault_tax); if($psi_onhand - $amt >=0){ if($vault_space_left + $amt_minus_tax >=0){ deposit($amt,$id,$amt_minus_tax); } } else{ header("LOCATION: vault.php?strErr=STORAGE SUMMARY<BR> You Need Enouph Space to Deposit ".number_format($amt)." Psi"); } // ///LINE 47 Below: // else{ header("LOCATION: vault.php?strErr=STORAGE SUMMARY<BR> You Do Not ".number_format($amt)." Psi To Deposit"); } } Any help would be cool.... Thanks Brian Flores AKA Dethman Link to comment https://forums.phpfreaks.com/topic/115964-solved-whats-up-with-this/ Share on other sites More sharing options...
mmarif4u Posted July 22, 2008 Share Posted July 22, 2008 I think you are using 2 else in the wrong way. change it elseif. Link to comment https://forums.phpfreaks.com/topic/115964-solved-whats-up-with-this/#findComment-596221 Share on other sites More sharing options...
MasterACE14 Posted July 22, 2008 Share Posted July 22, 2008 you have it. if() if() else { } else { } it needs to be: if() else { } if() else { } or in this codes case: if() else { } elseif() { } Regards ACE Link to comment https://forums.phpfreaks.com/topic/115964-solved-whats-up-with-this/#findComment-596246 Share on other sites More sharing options...
Juan Dela Cruz Posted July 22, 2008 Share Posted July 22, 2008 or in this codes case: if() else { } elseif() { } works?? Link to comment https://forums.phpfreaks.com/topic/115964-solved-whats-up-with-this/#findComment-596251 Share on other sites More sharing options...
Dethman Posted July 22, 2008 Author Share Posted July 22, 2008 Thanx Got it fixed for some damm reason I over look the elses and put them in wrong spot I guess Im sucky with the most basic things when I am tired... *TOPIC SOLVED* ------- Link to comment https://forums.phpfreaks.com/topic/115964-solved-whats-up-with-this/#findComment-596394 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.