php 解析/语法错误帮助

发布于 2024-11-17 06:31:28 字数 5174 浏览 1 评论 0原文

我不断收到

 "Parse error: syntax error, unexpected ':', expecting ')' in /home/jobkill/public_html/process.php on line 8"

当处理来自重定向到此处的页面的输入时, 。我不知道要修复什么,

这是代码:

<?
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$zipcode = @$_GET['zip'];
$state = @$_GET['custom_state'];
$subid = $_GET['subid'] ;
$urls = array(
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=23&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=80&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=46&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=37&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=55&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=71&zip=<?print $zipcode?>”);

$url = $urls[array_rand($urls)];

echo “<meta http-equiv=\"refresh\" content=3; url='$url'>”;

?>
<html>
<HEAD>
<LINK href="./index_files/style2.css" rel="stylesheet" type="text/css">
<STYLE>
#middlename
{
    display:none;
    visibility:hidden;
}
</STYLE>
<SCRIPT type="text/javascript" src="./index_files/scripts.js"></SCRIPT>
<SCRIPT type="text/javascript" 

src="./index_files/functions.js"></SCRIPT>

<script language="JavaScript" 

src="http://j.maxmind.com/app/geoip.js"></script>
</HEAD><BODY>

<DIV id="form_complete">

<!-- OPEN MAIN TABLE -->
<TABLE width="100%" height="850" border="0" align="center" 

cellpadding="0" cellspacing="0" class="tablebg2">
  <TBODY>
  <TR>
    <TD valign="top" align="center">


  <!-- OPEN PLACEMENT TABLE -->
  <table width="1010" height="500" border="0" cellspacing="0" 

cellpadding="0">

    <tr><td height="220" colspan="3">&nbsp;</td></tr>
    <tr>
      <td width="51%"><div align="center"><img 

src="index_files/blank.gif" border="0" width="425" height="344" 

/></div></td>
      <td 

width="10%">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp

;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td

>
      <td width="39%" align="left">


    &nbsp;
    <br /><br /><br />
    <div id="super-container0">
    <div id="wrapper">
      <span style="color:#000000;font-weight:bold;font-

size:24px;color:#898;">Now Searching...</span><br /><span 

style="color:#000000;font-weight:bold;font-size:32px;"><script 

language="Javascript">document.write(geoip_city());</script>, <script 

language="Javascript">document.write(geoip_region());</script></span>
      <!-- <h2>for <span style="color:#000000;font-weight:bold">30-

34</span> Year Old <span style="color:#000000;font-

weight:bold">Male</span> Drivers</h2> -->
      <div id="block"></div>
      <div id="progress-bar"><img src="index_files/progress.gif"></div>

    </div>
    </div>
    </DIV>






    </td>
  </tr>
  <tr>
    <td height="350" colspan="3">&nbsp;</td>
  </tr>
  <tr>

    <td colspan="3">
    <DIV class="Privacy" style="width: 1000px; margin: 0 auto;">
      <P style="font-family:Arial, Helvetica, sans-serif; font-

size:11px; margin: 0px; padding: 0px;">All personal information and 

email addresses are kept confidential. By           

submitting your expression of interest you are consenting to receive 

telephone calls from our participating partners even if you have been 

previously listed on a state or federal Do-Not-Call List.
    </P><P style="width: 1000px; text-align: center; margin-top: 0px; 

padding-top: 0px;"><A href="#" onclick="MM_openBrWindow

(&#39;privacy.htm&#39;,&#39;&#39;,&#39;scrollbars=yes,width=500,height=

400&#39;)" target="_blank" style="font-family:Arial, Helvetica, sans-

serif; font-size:10px; color:#03C">Privacy Policy</A></P>
</DIV></td>
  </tr>
</table> <!-- CLOSE PLACEMENT TABLE -->
</TD></TR></TABLE>  <!-- CLOSE MAIN TABLE -->



<DIV id="processing" style="display:none">
<br /><br /><br /><br />
<CENTER><img src="./index_files/logo2.gif" /><br /><br />
<H2>Searching for a specialist now ...<BR>Thank you for giving us an 

opportunity to assist you today.</H2><STRONG>(Please do not Refresh 

page as that will result in an error in the system.)</STRONG><BR>

  <IMG src="./index_files/ajax-loader.gif" width="220" height="19" 

alt="Processing">
</CENTER>
</DIV>

</BODY></html>

I keep getting a

 "Parse error: syntax error, unexpected ':', expecting ')' in /home/jobkill/public_html/process.php on line 8"

when processing inputs from a page that redirects here. I dont know what to fix,

Here's the code:

<?
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$zipcode = @$_GET['zip'];
$state = @$_GET['custom_state'];
$subid = $_GET['subid'] ;
$urls = array(
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=23&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=80&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=46&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=37&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=55&zip=<?print $zipcode?>”,
“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?

cdb=71&zip=<?print $zipcode?>”);

$url = $urls[array_rand($urls)];

echo “<meta http-equiv=\"refresh\" content=3; url='$url'>”;

?>
<html>
<HEAD>
<LINK href="./index_files/style2.css" rel="stylesheet" type="text/css">
<STYLE>
#middlename
{
    display:none;
    visibility:hidden;
}
</STYLE>
<SCRIPT type="text/javascript" src="./index_files/scripts.js"></SCRIPT>
<SCRIPT type="text/javascript" 

src="./index_files/functions.js"></SCRIPT>

<script language="JavaScript" 

src="http://j.maxmind.com/app/geoip.js"></script>
</HEAD><BODY>

<DIV id="form_complete">

<!-- OPEN MAIN TABLE -->
<TABLE width="100%" height="850" border="0" align="center" 

cellpadding="0" cellspacing="0" class="tablebg2">
  <TBODY>
  <TR>
    <TD valign="top" align="center">


  <!-- OPEN PLACEMENT TABLE -->
  <table width="1010" height="500" border="0" cellspacing="0" 

cellpadding="0">

    <tr><td height="220" colspan="3"> </td></tr>
    <tr>
      <td width="51%"><div align="center"><img 

src="index_files/blank.gif" border="0" width="425" height="344" 

/></div></td>
      <td 

width="10%">          

;           </td

>
      <td width="39%" align="left">


     
    <br /><br /><br />
    <div id="super-container0">
    <div id="wrapper">
      <span style="color:#000000;font-weight:bold;font-

size:24px;color:#898;">Now Searching...</span><br /><span 

style="color:#000000;font-weight:bold;font-size:32px;"><script 

language="Javascript">document.write(geoip_city());</script>, <script 

language="Javascript">document.write(geoip_region());</script></span>
      <!-- <h2>for <span style="color:#000000;font-weight:bold">30-

34</span> Year Old <span style="color:#000000;font-

weight:bold">Male</span> Drivers</h2> -->
      <div id="block"></div>
      <div id="progress-bar"><img src="index_files/progress.gif"></div>

    </div>
    </div>
    </DIV>






    </td>
  </tr>
  <tr>
    <td height="350" colspan="3"> </td>
  </tr>
  <tr>

    <td colspan="3">
    <DIV class="Privacy" style="width: 1000px; margin: 0 auto;">
      <P style="font-family:Arial, Helvetica, sans-serif; font-

size:11px; margin: 0px; padding: 0px;">All personal information and 

email addresses are kept confidential. By           

submitting your expression of interest you are consenting to receive 

telephone calls from our participating partners even if you have been 

previously listed on a state or federal Do-Not-Call List.
    </P><P style="width: 1000px; text-align: center; margin-top: 0px; 

padding-top: 0px;"><A href="#" onclick="MM_openBrWindow

('privacy.htm','','scrollbars=yes,width=500,height=

400')" target="_blank" style="font-family:Arial, Helvetica, sans-

serif; font-size:10px; color:#03C">Privacy Policy</A></P>
</DIV></td>
  </tr>
</table> <!-- CLOSE PLACEMENT TABLE -->
</TD></TR></TABLE>  <!-- CLOSE MAIN TABLE -->



<DIV id="processing" style="display:none">
<br /><br /><br /><br />
<CENTER><img src="./index_files/logo2.gif" /><br /><br />
<H2>Searching for a specialist now ...<BR>Thank you for giving us an 

opportunity to assist you today.</H2><STRONG>(Please do not Refresh 

page as that will result in an error in the system.)</STRONG><BR>

  <IMG src="./index_files/ajax-loader.gif" width="220" height="19" 

alt="Processing">
</CENTER>
</DIV>

</BODY></html>

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

初熏 2024-11-24 06:31:28

您的代码中的问题是引号。

此字符:

在 PHP 中无法识别为引号,您需要使用

'

或者

"

更新的代码

<?
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$subid = $_GET['subid'];

$zipcode = '';
if (isset($_GET['zip']) {
    $zipcode = $_GET['zip'];
}

$state = '';
if (isset($_GET['custom_state']) {
    $state = $_GET['custom_state'];
}

$urls = array(
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=80&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=46&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=37&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=55&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=71&zip=' . $zipcode);

$url = $urls[array_rand($urls)];
?>
<html>
    <head>
        <meta http-equiv="refresh" content=3; url='<? echo $url ?>'>
        <link href="./index_files/style2.css" rel="stylesheet" type="text/css">
        <style>
             #middlename
            {
                display:none;
                visibility:hidden;
            }
        </style>
        <script type="text/javascript" src="./index_files/scripts.js"></script>
        <script type="text/javascript" src="./index_files/functions.js"></script>
        <script type="text/javascript" src="http://j.maxmind.com/app/geoip.js"></script>
    </head>
    <body>
        <div id="form_complete">
            <!-- OPEN MAIN TABLE -->
            <table width="100%" height="850" border="0" align="center" cellpadding="0" cellspacing="0" class="tablebg2">
                <tbody>
                    <tr>
                        <td valign="top" align="center">
                            <!-- OPEN PLACEMENT TABLE -->
                            <table width="1010" height="500" border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                    <td height="220" colspan="3"> </td>
                                </tr>
                                <tr>
                                    <td width="51%">
                                        <div align="center">
                                            <img src="index_files/blank.gif" border="0" width="425" height="344" />
                                        </div>
                                    </td>
                                    <td width="10%">
                                                             
                                    </td>
                                    <td width="39%" align="left">
                                         <br /><br /><br />
                                        <div id="super-container0">
                                            <div id="wrapper">
                                                <span style="color:#000000;font-weight:bold;font-size:24px;color:#898;">Now Searching...</span><br />
                                                <span style="color:#000000;font-weight:bold;font-size:32px;">
                                                <script type="text/javascript">document.write(geoip_city());</script>,
                                                <script type="text/javascript">document.write(geoip_region());</script>
                                                </span>
                                                <!-- <h2>for <span style="color:#000000;font-weight:bold">30-34</span> Year Old 
                                                <span style="color:#000000;font-weight:bold">Male</span> Drivers</h2> -->
                                                <div id="block"></div>
                                                <div id="progress-bar"><img src="index_files/progress.gif"></div>
                                            </div>
                                        </div>
                                    </td>
                                </tr>
                                <tr>
                                    <td height="350" colspan="3"> </td>
                                </tr>
                                <tr>
                                    <td colspan="3">
                                        <div class="Privacy" style="width: 1000px; margin: 0 auto;">
                                            <p style="font-family:Arial, Helvetica, sans-serif; font-size:11px; margin: 0px; padding: 0px;">All personal information and 
                                                email addresses are kept confidential. By submitting your expression of interest you are consenting to receive 
                                                telephone calls from our participating partners even if you have been 
                                                previously listed on a state or federal Do-Not-Call List.</p>
                                            <p style="width: 1000px; text-align: center; margin-top: 0px; padding-top: 0px;"><a href="#" onclick="MM_openBrWindow('privacy.htm','','scrollbars=yes,width=500,height=400')" target="_blank" style="font-family:Arial, Helvetica, sans-serif; font-size:10px; color:#03C">Privacy Policy</a></p>
                                        </div>
                                    </td>
                                </tr>
                            </table> <!-- CLOSE PLACEMENT TABLE -->
                        </td>
                    </tr>
                </tbody>
            </table>  <!-- CLOSE MAIN TABLE -->
        </div>
        <div id="processing" style="display:none">
            <br /><br /><br /><br />
            <center>
                <img src="./index_files/logo2.gif" /><br /><br />
                <H2>Searching for a specialist now ...<BR>Thank you for giving us an opportunity to assist you today.</h2>
                <strong>(Please do not Refresh page as that will result in an error in the system.)</strong><br>
                <img src="./index_files/ajax-loader.gif" width="220" height="19" alt="Processing">
            </center>
        </div>
    </body>
</html>

这是我还

  • ...修复了几个 HTML 错误,缺少结束标记或嵌套错误
  • 而不是在 PHP 中使用错误抑制 ( @$_GET['mightnotexist']) 我已经执行了 isset($_GET['mightnotexist']) 检查
  • 我已经标准化了脚本标签

但我还没有...

  • 删除了用于布局的表格
  • 将内联样式移至样式表

The problem in your code are the quotes.

This character:

Is not recognised as a quotation in PHP, you need to use

'

Or

"

Here is the updated code

<?
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$subid = $_GET['subid'];

$zipcode = '';
if (isset($_GET['zip']) {
    $zipcode = $_GET['zip'];
}

$state = '';
if (isset($_GET['custom_state']) {
    $state = $_GET['custom_state'];
}

$urls = array(
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=80&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=46&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=37&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=55&zip=' . $zipcode,
    'http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=71&zip=' . $zipcode);

$url = $urls[array_rand($urls)];
?>
<html>
    <head>
        <meta http-equiv="refresh" content=3; url='<? echo $url ?>'>
        <link href="./index_files/style2.css" rel="stylesheet" type="text/css">
        <style>
             #middlename
            {
                display:none;
                visibility:hidden;
            }
        </style>
        <script type="text/javascript" src="./index_files/scripts.js"></script>
        <script type="text/javascript" src="./index_files/functions.js"></script>
        <script type="text/javascript" src="http://j.maxmind.com/app/geoip.js"></script>
    </head>
    <body>
        <div id="form_complete">
            <!-- OPEN MAIN TABLE -->
            <table width="100%" height="850" border="0" align="center" cellpadding="0" cellspacing="0" class="tablebg2">
                <tbody>
                    <tr>
                        <td valign="top" align="center">
                            <!-- OPEN PLACEMENT TABLE -->
                            <table width="1010" height="500" border="0" cellspacing="0" cellpadding="0">
                                <tr>
                                    <td height="220" colspan="3"> </td>
                                </tr>
                                <tr>
                                    <td width="51%">
                                        <div align="center">
                                            <img src="index_files/blank.gif" border="0" width="425" height="344" />
                                        </div>
                                    </td>
                                    <td width="10%">
                                                             
                                    </td>
                                    <td width="39%" align="left">
                                         <br /><br /><br />
                                        <div id="super-container0">
                                            <div id="wrapper">
                                                <span style="color:#000000;font-weight:bold;font-size:24px;color:#898;">Now Searching...</span><br />
                                                <span style="color:#000000;font-weight:bold;font-size:32px;">
                                                <script type="text/javascript">document.write(geoip_city());</script>,
                                                <script type="text/javascript">document.write(geoip_region());</script>
                                                </span>
                                                <!-- <h2>for <span style="color:#000000;font-weight:bold">30-34</span> Year Old 
                                                <span style="color:#000000;font-weight:bold">Male</span> Drivers</h2> -->
                                                <div id="block"></div>
                                                <div id="progress-bar"><img src="index_files/progress.gif"></div>
                                            </div>
                                        </div>
                                    </td>
                                </tr>
                                <tr>
                                    <td height="350" colspan="3"> </td>
                                </tr>
                                <tr>
                                    <td colspan="3">
                                        <div class="Privacy" style="width: 1000px; margin: 0 auto;">
                                            <p style="font-family:Arial, Helvetica, sans-serif; font-size:11px; margin: 0px; padding: 0px;">All personal information and 
                                                email addresses are kept confidential. By submitting your expression of interest you are consenting to receive 
                                                telephone calls from our participating partners even if you have been 
                                                previously listed on a state or federal Do-Not-Call List.</p>
                                            <p style="width: 1000px; text-align: center; margin-top: 0px; padding-top: 0px;"><a href="#" onclick="MM_openBrWindow('privacy.htm','','scrollbars=yes,width=500,height=400')" target="_blank" style="font-family:Arial, Helvetica, sans-serif; font-size:10px; color:#03C">Privacy Policy</a></p>
                                        </div>
                                    </td>
                                </tr>
                            </table> <!-- CLOSE PLACEMENT TABLE -->
                        </td>
                    </tr>
                </tbody>
            </table>  <!-- CLOSE MAIN TABLE -->
        </div>
        <div id="processing" style="display:none">
            <br /><br /><br /><br />
            <center>
                <img src="./index_files/logo2.gif" /><br /><br />
                <H2>Searching for a specialist now ...<BR>Thank you for giving us an opportunity to assist you today.</h2>
                <strong>(Please do not Refresh page as that will result in an error in the system.)</strong><br>
                <img src="./index_files/ajax-loader.gif" width="220" height="19" alt="Processing">
            </center>
        </div>
    </body>
</html>

I have also...

  • Fixed a couple of HTML errors, with missing closing tags or bad nesting
  • Rather than using error suppression in PHP (@$_GET['mightnotexist']) I have performed an isset($_GET['mightnotexist']) check
  • I have normalised the script tags

But I haven't...

  • Removed the tables being used for layout
  • Moved the inline styles into the stylesheet
冬天的雪花 2024-11-24 06:31:28

更新
添加了整个代码,经过测试并工作

替换 >与 $zipcode

“http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=”,
进入 “http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=$zipcode”,

并将引号 (“”) 替换为正常 基本上你的代码

应该是这样的:

<?php
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$zipcode = @$_GET['zip'];
$state = @$_GET['custom_state'];
$subid = $_GET['subid'] ;
$urls = array(
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=80&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=46&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=37&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=55&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=71&zip=$zipcode");

$url = $urls[array_rand($urls)];
?>
<html>
<HEAD>
<LINK href="./index_files/style2.css" rel="stylesheet" type="text/css">
<STYLE>
#middlename
{
    display:none;
    visibility:hidden;
}
</STYLE>
<SCRIPT type="text/javascript" src="./index_files/scripts.js"></SCRIPT>
<SCRIPT type="text/javascript" 

src="./index_files/functions.js"></SCRIPT>

<script language="JavaScript" 

src="http://j.maxmind.com/app/geoip.js"></script>
<meta http-equiv="refresh" content="3;url=<?php echo $url; ?>"> 
</HEAD><BODY>

<DIV id="form_complete">

<!-- OPEN MAIN TABLE -->
<TABLE width="100%" height="850" border="0" align="center" 

cellpadding="0" cellspacing="0" class="tablebg2">
  <TBODY>
  <TR>
    <TD valign="top" align="center">


  <!-- OPEN PLACEMENT TABLE -->
  <table width="1010" height="500" border="0" cellspacing="0" 

cellpadding="0">

    <tr><td height="220" colspan="3"> </td></tr>
    <tr>
      <td width="51%"><div align="center"><img 

src="index_files/blank.gif" border="0" width="425" height="344" 

/></div></td>
      <td 

width="10%">          

;           </td

>
      <td width="39%" align="left">


     
    <br /><br /><br />
    <div id="super-container0">
    <div id="wrapper">
      <span style="color:#000000;font-weight:bold;font-

size:24px;color:#898;">Now Searching...</span><br /><span 

style="color:#000000;font-weight:bold;font-size:32px;"><script 

language="Javascript">document.write(geoip_city());</script>, <script 

language="Javascript">document.write(geoip_region());</script></span>
      <!-- <h2>for <span style="color:#000000;font-weight:bold">30-

34</span> Year Old <span style="color:#000000;font-

weight:bold">Male</span> Drivers</h2> -->
      <div id="block"></div>
      <div id="progress-bar"><img src="index_files/progress.gif"></div>

    </div>
    </div>
    </DIV>






    </td>
  </tr>
  <tr>
    <td height="350" colspan="3"> </td>
  </tr>
  <tr>

    <td colspan="3">
    <DIV class="Privacy" style="width: 1000px; margin: 0 auto;">
      <P style="font-family:Arial, Helvetica, sans-serif; font-

size:11px; margin: 0px; padding: 0px;">All personal information and 

email addresses are kept confidential. By           

submitting your expression of interest you are consenting to receive 

telephone calls from our participating partners even if you have been 

previously listed on a state or federal Do-Not-Call List.
    </P><P style="width: 1000px; text-align: center; margin-top: 0px; 

padding-top: 0px;"><A href="#" onclick="MM_openBrWindow

('privacy.htm','','scrollbars=yes,width=500,height=

400')" target="_blank" style="font-family:Arial, Helvetica, sans-

serif; font-size:10px; color:#03C">Privacy Policy</A></P>
</DIV></td>
  </tr>
</table> <!-- CLOSE PLACEMENT TABLE -->
</TD></TR></TABLE>  <!-- CLOSE MAIN TABLE -->



<DIV id="processing" style="display:none">
<br /><br /><br /><br />
<CENTER><img src="./index_files/logo2.gif" /><br /><br />
<H2>Searching for a specialist now ...<BR>Thank you for giving us an 

opportunity to assist you today.</H2><STRONG>(Please do not Refresh 

page as that will result in an error in the system.)</STRONG><BR>

  <IMG src="./index_files/ajax-loader.gif" width="220" height="19" 

alt="Processing">
</CENTER>
</DIV>

</BODY></html>

UPDATE:
added whole code, tested and working

replace <?print $zipcode?> with $zipcode

i.e. “http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=<?print $zipcode?>”,
into “http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=$zipcode”,

and replace quotation marks (“”) to normal ones ("")

basically your code should look like this:

<?php
$aff = $_GET['aff'] ;
$click_id = $_GET['click_id'] ;
$zipcode = @$_GET['zip'];
$state = @$_GET['custom_state'];
$subid = $_GET['subid'] ;
$urls = array(
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=23&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=80&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=46&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=37&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=55&zip=$zipcode",
"http://consumerheadlinesdaily.com/debt/direct_2de89f.php?cdb=71&zip=$zipcode");

$url = $urls[array_rand($urls)];
?>
<html>
<HEAD>
<LINK href="./index_files/style2.css" rel="stylesheet" type="text/css">
<STYLE>
#middlename
{
    display:none;
    visibility:hidden;
}
</STYLE>
<SCRIPT type="text/javascript" src="./index_files/scripts.js"></SCRIPT>
<SCRIPT type="text/javascript" 

src="./index_files/functions.js"></SCRIPT>

<script language="JavaScript" 

src="http://j.maxmind.com/app/geoip.js"></script>
<meta http-equiv="refresh" content="3;url=<?php echo $url; ?>"> 
</HEAD><BODY>

<DIV id="form_complete">

<!-- OPEN MAIN TABLE -->
<TABLE width="100%" height="850" border="0" align="center" 

cellpadding="0" cellspacing="0" class="tablebg2">
  <TBODY>
  <TR>
    <TD valign="top" align="center">


  <!-- OPEN PLACEMENT TABLE -->
  <table width="1010" height="500" border="0" cellspacing="0" 

cellpadding="0">

    <tr><td height="220" colspan="3"> </td></tr>
    <tr>
      <td width="51%"><div align="center"><img 

src="index_files/blank.gif" border="0" width="425" height="344" 

/></div></td>
      <td 

width="10%">          

;           </td

>
      <td width="39%" align="left">


     
    <br /><br /><br />
    <div id="super-container0">
    <div id="wrapper">
      <span style="color:#000000;font-weight:bold;font-

size:24px;color:#898;">Now Searching...</span><br /><span 

style="color:#000000;font-weight:bold;font-size:32px;"><script 

language="Javascript">document.write(geoip_city());</script>, <script 

language="Javascript">document.write(geoip_region());</script></span>
      <!-- <h2>for <span style="color:#000000;font-weight:bold">30-

34</span> Year Old <span style="color:#000000;font-

weight:bold">Male</span> Drivers</h2> -->
      <div id="block"></div>
      <div id="progress-bar"><img src="index_files/progress.gif"></div>

    </div>
    </div>
    </DIV>






    </td>
  </tr>
  <tr>
    <td height="350" colspan="3"> </td>
  </tr>
  <tr>

    <td colspan="3">
    <DIV class="Privacy" style="width: 1000px; margin: 0 auto;">
      <P style="font-family:Arial, Helvetica, sans-serif; font-

size:11px; margin: 0px; padding: 0px;">All personal information and 

email addresses are kept confidential. By           

submitting your expression of interest you are consenting to receive 

telephone calls from our participating partners even if you have been 

previously listed on a state or federal Do-Not-Call List.
    </P><P style="width: 1000px; text-align: center; margin-top: 0px; 

padding-top: 0px;"><A href="#" onclick="MM_openBrWindow

('privacy.htm','','scrollbars=yes,width=500,height=

400')" target="_blank" style="font-family:Arial, Helvetica, sans-

serif; font-size:10px; color:#03C">Privacy Policy</A></P>
</DIV></td>
  </tr>
</table> <!-- CLOSE PLACEMENT TABLE -->
</TD></TR></TABLE>  <!-- CLOSE MAIN TABLE -->



<DIV id="processing" style="display:none">
<br /><br /><br /><br />
<CENTER><img src="./index_files/logo2.gif" /><br /><br />
<H2>Searching for a specialist now ...<BR>Thank you for giving us an 

opportunity to assist you today.</H2><STRONG>(Please do not Refresh 

page as that will result in an error in the system.)</STRONG><BR>

  <IMG src="./index_files/ajax-loader.gif" width="220" height="19" 

alt="Processing">
</CENTER>
</DIV>

</BODY></html>
长伴 2024-11-24 06:31:28

将 echo 中的“refresh”替换为“refresh”

<?print $zipcode?> 

在数组中
$邮政编码

replace "refresh" in your echo with \"refresh\"
and

<?print $zipcode?> 

in array with
$zipcode

偏闹i 2024-11-24 06:31:28

更新:

检查了您的代码并能够重现您的错误。您没有使用双引号,而是使用了 PHP 不支持的其他一些晦涩的引号。

正确的双引号实际上是 "。您可以 了解PHP 手册中的详细信息

您可能在从互联网上的其他地方复制和粘贴代码时犯了一个错误,该代码由于样式和显示原因而动态更改代码的引用。

请注意代码中的其他问题。站起来(也请参阅其他答案)


echo "<meta http-equiv=\"refresh\" content=\"3; url='$url'\">";

而不是屏幕截图中类似但不同的行(它不是文本,所以我无法引用它并突出显示您在其中犯错误的地方,很抱歉,

这不会创建您所询问的语法错误 )。大约然而。

Update:

Checked your code and was able to reproduce your error. You're not using double quotes but some other obscure quotes that is not supported by PHP.

Proper double quotes are literally ". You can learn about the details in the PHP manual.

You probably made an error while copy and pasting code from somewhere else in the internet that was changing code's quote's on the fly for styling and display reason.

Take care. The other problems in your code still stand (see other answers as well).


Try

echo "<meta http-equiv=\"refresh\" content=\"3; url='$url'\">";

instead of the similar but different line in your screenshot (it's no text, so I can't quote it and highlight the places you made errors in there, so sorry 'bout that).

This does not create the syntax error you're asking about however.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文