Necesito reemplazar esta oración en javascript de variables php.
draw:{circle:false, circlemarker:false, rectangle:false, polyline:false, polygon:false},por sorteo: sorteo ,
así que traté de llamar a esta variable por
if($geometry == Point){ echo "var drawchoice = \"" {circle:false, circlemarker:false, rectangle:false, polyline:false, polygon:false}, "\";\n"; } if($geometry == LineString){ echo "var drawchoice = \"" {circle:false, circlemarker:false, rectangle:false, marker:false, polygon:false}, "\";\n"; } if($geometry == Polygon){ echo "var drawchoice = \"" {circle:false, circlemarker:false, rectangle:false, marker:false, polyline:false}, "\";\n"; }Pero php -l dice:
Error de PHP Parse: error de sintaxis, token inesperado ":" en /var/www/html/pgtest/test1.php en la línea 48
¿Cuál es la escritura correcta?