Using String interpolation in php

DevOps

YOUR COSMETIC CARE STARTS HERE

Find the Best Cosmetic Hospitals

Trusted • Curated • Easy

Looking for the right place for a cosmetic procedure? Explore top cosmetic hospitals in one place and choose with confidence.

“Small steps lead to big changes — today is a perfect day to begin.”

Explore Cosmetic Hospitals Compare hospitals, services & options quickly.

✓ Shortlist providers • ✓ Review options • ✓ Take the next step with confidence

String interpolation is quick shortcut, allowing to pop up the value of a variable into double quoted String. Remember that any variable with “$” sign into single quote is not a variable, it just treat as a statement.

eg. ‘$num is not a variable’ because num variable is written into single quote.

<?php
    $value= 10;
    echo "$value is good price of the product"; //<strong>String interpolation</strong>
    echo '$value is good price of the product';
?>Code language: HTML, XML (xml)