got this annoying error
I'm completly new to php... and i have no clue what is wrong here, from what i can tell there is nothing rong with this code... but that isn't what the borwser say :P
Parse error: parse error, unexpected T_VARIABLE in main.php on line 15
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<head>
<title></title>
<head/>
<body style="backgrou nd-color: transparent">
<?php
$file=fopen("ne ws.txt","r") or exit("Unable to open file!");
$first = 1
$ordn = fgetc($file);
fgets($file);
while (!feof($file))
{
if $first = 1
{
$check = fgetc($file);
$first = 0
}
if $check = "_"
{
$check = fgetc($file);
}
if $check = $ordn
{
$ordn = $ordn - 1
while $check(!"_")
{
echo fgets($file);
$check = fgetc($file);
}
}
else
{
fgets($file);
$check = fgetc($file);
}
}
fclose($file);
?>
</body>
</html>
NEXT TIME ENCLOSE YOUR CODE WITHIN PHP, CODE OR HTML TAGS!! READ THE POSTING GUIDLINES BEFORE POSTING ANYTHING IN THIS FORUM! - Ronald :cool:
I'm completly new to php... and i have no clue what is wrong here, from what i can tell there is nothing rong with this code... but that isn't what the borwser say :P
Parse error: parse error, unexpected T_VARIABLE in main.php on line 15
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
<html>
<head>
<title></title>
<head/>
<body style="backgrou nd-color: transparent">
<?php
$file=fopen("ne ws.txt","r") or exit("Unable to open file!");
$first = 1
$ordn = fgetc($file);
fgets($file);
while (!feof($file))
{
if $first = 1
{
$check = fgetc($file);
$first = 0
}
if $check = "_"
{
$check = fgetc($file);
}
if $check = $ordn
{
$ordn = $ordn - 1
while $check(!"_")
{
echo fgets($file);
$check = fgetc($file);
}
}
else
{
fgets($file);
$check = fgetc($file);
}
}
fclose($file);
?>
</body>
</html>
NEXT TIME ENCLOSE YOUR CODE WITHIN PHP, CODE OR HTML TAGS!! READ THE POSTING GUIDLINES BEFORE POSTING ANYTHING IN THIS FORUM! - Ronald :cool:
Comment