语法错误,在/home/u663911524/public_html/sitemap中出现意外的“require”(T_REQUIRE)。php在第3行

时间:2020-12-08 22:34:25

Parse error: syntax error, unexpected 'require' (T_REQUIRE) in /home/u663911524/public_html/sitemap.php on line 3

语法错误,在/home/u663911524/public_html/sitemap中出现意外的“require”(T_REQUIRE)。php在第3行

I have searched online for solutions for a while and none seem to be working. Any help would be greatly appreciated! I'm still new to php as well.

我在网上搜索解决方案已经有一段时间了,但似乎没有一个有效。如有任何帮助,我们将不胜感激!我对php还是很陌生的。

Here are the first couple of lines of code:

以下是前几行代码:

<? php     
require("sitemap.cfg");
$isoLastModifiedSite = "";
$newLine = "\n";
$indent = " ";
if (!$rootUrl) exit;

2 个解决方案

#1


2  

Just Change

只改变

<? php

to

<?php

And the error will be fixed.

误差会被修正。

#2


0  

There is an space between <? and php

Erase it

把它擦掉

#1


2  

Just Change

只改变

<? php

to

<?php

And the error will be fixed.

误差会被修正。

#2


0  

There is an space between <? and php

Erase it

把它擦掉