Quotation Marks
-
Have different meanings.
-
Single quotes: take it literally.
-
Double quotes: evaluate what is in the quotes. Use for concatenations
of strings and variables.
-
Example:
$studentName = "Spiff Goodman";
print 'The student\'s name is: $studentName';
print "The student\'s name is: $studentName";
-
The first print line will result in
The student's name is: $studentName
-
And the second will result in
The student's name is: Spiff Goodman
Creating a Script
Home