$net_price = "var net_price = " . json_encode($net_price) . ";";
This is a Javascript variable being created inside of a PHP string.