如何启用 PHP 短标签?
我在 Linux 服务器上有一个以 <?
I have a web application on a Linux server which starts with <?
我需要将此应用程序复制到 Windows 环境中,并且一切正常,只是 SQL 语句的呈现方式不同.我不知道这是否与以 <?php
而不是 <?
开头的脚本有关,因为我不知道从哪里启用 <<?
来自 PHP.ini
所以我将其更改为 <?php
I needed to copy this application to a windows environment and everything is working fine except that an SQL statement is being rendered differently. I don't know if this has to do with the script beginning with <?php
instead of <?
because I don't know from where to enable the <?
from the PHP.ini
so I changed it to <?php
我知道这 2 个语句的含义应该相同,但我需要使用 <?
对其进行测试,以确保应用程序完全相同.这样我可以排除另一种可能性.
I know that these 2 statements are supposed to mean the same but I need to test it with <?
in order to ensure that the application is exactly the same. This way I can eliminate another possibility.
谢谢
推荐答案
设置
short_open_tag=On
在 php.ini
然后重新启动您的 Apache 服务器.
And restart your Apache server.
相关文章