Nate Weiner

  • Archive
  • RSS

Cleaner Print Command in PHP

Stumbled upon this by accident and I haven’t been able to find anything in the PHP documentation because you can’t search for non-alpha characters, but this find has cleaned up my code a ton.

<?php print ‘Hello World’; ?>

Works the same as:

<?= ‘Hello World’ ?>

I’m using PHP 5, so I don’t know if this works in previous versions.

    • #php
  • 4 years ago
  • Permalink
  • Share
    Tweet
← Previous • Next →

About

Prototyper, water waster, developer of Read It Later.

 

Follow

Twitter: @NateWeiner
Vimeo: Nate Weiner
500px: Nate Weiner
Blog: RSS

Pages

  • Contact
  • RSS
  • Random
  • Archive
  • Mobile

Effector Theme by Carlo Franco.

Powered by Tumblr