i'm trying to make a form that takes a users input and runs it through a javascript for output. that is working fine, where i am getting hung up is setting the script to contain a default output before the user has put in anything.
I'm familiar with other languages, i just can't find the correct syntax to check whether a variable contains a value, and if not assign it one
ie
if !$query {
$query=default;
echo $query; //obviously echos "default"
} else {
echo $query;
then run some stuff;
}//end if
but it's that !$query thing i'm getting stuck on