FOLLOW US
softpcapps Software CODE HELP BLOG



Freeware Open Source Windows Software Applications and Free Online Tools

For Windows 11 : Download and run .NET 3.5 Installer if the application is not running

How to Use PHP Variables inside HTML Tags without Echo

To use php variables inside HTML tags, without using an echo command, you can use the shorthand-type <?= ?>


For example :


$PAGEURL='https://softpcapps.com';

<a href="https://www.facebook.com/sharer/sharer.php?u=<?=$PAGEURL ?>">

will output :


<a href="https://www.facebook.com/sharer/sharer.php?u=https://softpcapps.com">