Skip to content

Instantly share code, notes, and snippets.

@phpfiddle
Created April 20, 2018 10:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save phpfiddle/a571a4b212a346f5b865d3db2d05bce0 to your computer and use it in GitHub Desktop.
Save phpfiddle/a571a4b212a346f5b865d3db2d05bce0 to your computer and use it in GitHub Desktop.
[ Posted by Eupseu@mail.ru ] https://otvet.mail.ru/question/207947711
<pre>
<?php
$var = "семен петрович";
$arr = ['c кавычками'=>'\''.$var."'", 'без кавычек'=>$var, 'второй варииант'=>"'$var'", 'по другому'=>"\"$var\"", 'по другому2'=>'"'.$var.'"', 'жестоко'=>'&laquo;'.$var.'&raquo;'];
print_r($arr);
?></pre>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment