spydaddy Posted June 26, 2009 Share Posted June 26, 2009 Hi, I am new to the forum, and new to php. We had a developer create some code that - after developer was gone - turned out to be in php. We are running on Windows, under IIS. The code has a bug, where snippets of the code that are surrounded with <?=somevariable?> do not execute. <?php some code here ?> executes just fine. Can you guys help? I am sure it is something very simple. Thanks Link to comment https://forums.phpfreaks.com/topic/163802-solved-code-snippets-are-not-executing-on-windows/ Share on other sites More sharing options...
PFMaBiSmAd Posted June 26, 2009 Share Posted June 26, 2009 ; NOTE: Using short tags should be avoided when developing applications or ; libraries that are meant for redistribution, or deployment on PHP ; servers which are not under your control, because short tags may not ; be supported on the target server. For portable, redistributable code, ; be sure not to use short tags. No programmer should be using the lazy-way short open tags, especially if he is being paid to write the code. You should go through the code and change them or you can turn on the short_open_tag setting. Link to comment https://forums.phpfreaks.com/topic/163802-solved-code-snippets-are-not-executing-on-windows/#findComment-864275 Share on other sites More sharing options...
WolfRage Posted June 26, 2009 Share Posted June 26, 2009 Damn got beat to the punch..... Either you have to enable short tags. Not reccomended. Or simply convert all "<?" to "<?php" which is standard syntax for opening tags. Link to comment https://forums.phpfreaks.com/topic/163802-solved-code-snippets-are-not-executing-on-windows/#findComment-864276 Share on other sites More sharing options...
spydaddy Posted June 26, 2009 Author Share Posted June 26, 2009 Thanks, guys. that worked. Although it is quite a bit of rework to get it working everywhere. And I don't like that I have to use "<?php print" everywhere where he used "<?="....the latter is more intuitive, and less prone to forgotten extra spaces... Link to comment https://forums.phpfreaks.com/topic/163802-solved-code-snippets-are-not-executing-on-windows/#findComment-864340 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.