WordPress Question:
Download Questions PDF

Tell me Would you initialize your strings with single quotes or double quotes?

Answer:

Since the data inside the single-quoted string is not parsed for variable substitution, it’s always a better idea speed-wise to initialize a string with single quotes, unless you specifically need variable substitution.

Download WordPress (CMS) Interview Questions And Answers PDF

Previous QuestionNext Question
How come the code
<?php print “Contents: $arr[1]“; ?>
works, but
<?php print “Contents: $arr[1][2]“; ?>
doesn’t for two-dimensional array of mine?
Do you know Why doesn’t the following code print the newline properly?