Jump to content

Script/Program to convert '<?' into '<?php'


guarriman

Recommended Posts

Hi.

 

I want to migrate from PHP4 (where I use '<?') to PHP5 (where I must use '<?php').

 

Do you know a program or a Linux script to do it? Thank you very much.

 

Why not just use a text editor like NotePad phpDesigner or any other and use Find & Replace?

 

Find: <?

 

Replace with: <?php

Hi.

 

I want to migrate from PHP4 (where I use '<?') to PHP5 (where I must use '<?php').

 

Do you know a program or a Linux script to do it? Thank you very much.

PHP5 does support the short tags (<? and <?php=) all you need to do is enable a setting called short_open_tag. However if your script is small then I'd recommend you to convert the short tags to their respective full version.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.