Why are you using double quotes? - You're getting very confused about their usage and the difference between PHP and mysql's use of quote marks.
This is how you should do it:
$query = "INSERT INTO log VALUES(
Your query is already inside double quotes. Therefore the $Variables will still be replaced with their values inside the single quotes.
For mysql, you always wrap values in single quotes and optionally wrap column names in backticks ` (which you've not specified in your query btw - insert into <table> (`columns`) values ('$Values');
In php anything inside single quotes (unless inside a double quoted string) will be exactly as you see it:
$Name = 'Joe Bloggs';
$Str = 'Name is $Name'; // Name is $Name
$Str = "Name is $Name"; // Name is Joe Bloggs
$Query = "insert into <table> (`column`) values ('$Name')"; //insert into <table> (`column`) values ('Joe Bloggs')
For more information, see the Quotes tip in my signature.