What are some potential syntax errors to watch out for when working with PHP variables and how can they impact the functionality of a script?

One common syntax error when working with PHP variables is forgetting to include the dollar sign ($) before the variable name when assigning or referencing it. This can lead to unexpected behavior or errors in the script. To avoid this issue, always ensure that variables are properly prefixed with the dollar sign.

// Incorrect variable assignment
myVariable = "Hello World";

// Correct variable assignment
$myVariable = "Hello World";