PDA

View Full Version : Does dreamweaver have syntax error highlighting?


whitedragon101
10-13-2009, 03:33 AM
I have just spent hours finding out that my php page had an sql query that read:

$sql2="INSERT INTO customer (`username`, `password`, `first_name`, `last_name`, `address`, `telephone`, `email`,`business_name`,`website',`account_type`, `datejoined`)VALUES('$username','$password','$firs t_name','$last_name','$address','$telephone','$ema il','$business_name','$website','$account_type','$ date_joined')";instead of:

$sql2="INSERT INTO customer (`username`, `password`, `first_name`, `last_name`, `address`, `telephone`, `email`,`business_name`,`website`,`account_type`, `datejoined`)VALUES('$username','$password','$firs t_name','$last_name','$address','$telephone','$ema il','$business_name','$website','$account_type','$ date_joined')";Did you spot the difference?.....
Yep it was the ' after website instead of a ` . But in 1000's of lines of code it took hours to figure that out. So to the question....

Does Dreamweaver have sql or php syntax error highlighting?
If not is there another way that these simple syntax problems can be flagged and found more easily?

edbr
10-13-2009, 04:02 AM
drives you crazy doesnt it! no im afraid not . best solution is to make a set of snippets to help reduce errors but not perfect. i like html-kit for php with a few of its plugins added . i also like that its free