Write a program to print a string using echo+variable.
Description:
Write a program to print “Welcome to the PHP World” using some part of the text in variable & some part directly in echo.
Conditions:
- You have to use a variable that contains string “PHP World”.
View Solution/Program
<?php
$message = "Welcome to the PHP World";
echo $message;
?>
Tutorials Class - Output Window
Welcome to the PHP World
Learn more about the similar topics:
| Tutorials |
|---|
| PHP Variables |
| Interview Questions & Answers |
|---|
| How to check if a variable is empty in PHP? |
| Is PHP a case sensitive language? |
| What are the different data types in PHP? |