stefh 0 Light Poster

Hi everyone :)

Does someone have a solution to use single and double quote with php cli when passing code with the -r option?

Example, this won't work:

$ php -r 'echo 'ok'; echo "ok";'

I'm looking for a solution that allows me to use single AND double quotes in the same code...

Thanks for your help!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.