Jump to content
MakeWebGames

Need a little help :)


DELETE-ME-NOW-

Recommended Posts

Ive been trying to make it that you can unlock new areas in explore, main menu, and other places as you level up.

As an exampe, ive been trying this:

42. if($ir['level'] > 20)

43. {

44. Auction Market

 

But this results in : Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home2/mafiakil/public_html/explore.php on line 42

.

I have tryed loads of different ways to fix it, but none have worked :(

Link to comment
Share on other sites

There is no error in the code I posted, make sure you're ending the current "print" before you put that statement.

I think you're doing something like this which is wrong...

 

print " Blah Blah Blah if($ir['level'] > 20) { echo ('[url="Auction.php"]Auction Market[/url]
'); } Blah Blah Blah "; 
Link to comment
Share on other sites

print"[url='itemsearch.php']Search Player Shops[/url]
";   # that if you are using print or '; if using echo
if($ir['level'] > 20) { echo ('[url='Auction.php']Auction Market[/url]
'); }


# or echo'   whichever you rather
print"
[url='itemmarket.php']Item Market[/url]
Link to comment
Share on other sites

<?php
include "globals.php";
$tresder=(int) rand(100,999);
if($ir['jail'] > 0)
{
die("[b]<font color=red size=+1>You are in Jail for {$ir['jail']} more minute(s).

Until you are out you can't view this page</font>[/b]


[url='jail.php']Return to Jail[/url]");
}
if($ir['hospital'] > 0)
{
die("[b]<font color=red size=+1>You are in the Hospital for {$ir['hospital']} more minute(s).

Until you are out you can't view this page</font>[/b]


[url='hospital.php']Return to Hospital[/url]");
}
print "

<center><table width='715' height='385' border='1' cellpadding='2' class='tablejf1'><center></font><font color=red></font>This is your referal link: http://game-name.com/register.php?REF=$userid 

Every signup from this link earns you 30 valuable Points!
<tr background='header.gif'></font><font color=red></font>
<td height='25'><div align='center'>[b]
<font color=white><u></font><font color=red>Market</u></u>[/b]</div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Living Quarters<u/>[/b]</u></div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Cash Industry</u></font>[/b]</u></div>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Dark Side<u/>[/b]</u></div></td></td>
</tr>
<tr>
!NEW!
<td><div align='center'>[b]
[url='shops.php']Game Shops[/url]

[url='myshop.php']Your Shop[/url]

[url='playershops.php']Player Shops[/url]

print'[url='itemsearch.php']Search Player Shops[/url]
';
if($ir['level'] > 20) { echo ('[url='Auction.php']Auction Market[/url]
'); }
print'
[url='itemmarket.php']Item Market[/url]

[url='cmarket.php']Points Market[/url]
</td>
[/b]</div></td>

<td><div align='center'>[b]
[url='monorail.php']Travel[/url]

[url='houses.php']Houses[/url]<br 
[url='pointbank.php']Points Bank[/url]
</td>
[/b]</div></td>

<td><div align='center'>[b]
[url='bank.php']City Bank[/url]

[url='creditcard.php']Credit Card[/url]

[url='business_view.php']Business listings[/url]

[url='business_create.php']Create a business[/url]

[url='business_home.php']Your business[/url]

[/b]</div></td>

<td><div align='center'>[b]
[url='crystaltemple.php']Points Temple[/url]

[url='hitmanagency.php']Hitman Agency[/url]

[url='marital.php']Marital Agency[/url]

[url='donatorlist.php']View Donators[/url]

[url='gymrecord.php']Gym Record[/url]

[url='games.php']Arcade[/url]

</div>[/b]</td>

</tr>
<tr background='header.gif'>
<td height='25'><div align='center'>[b]
<font color=white><u></font><font color=red>Statistics Dept</u>[/b]</u></div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Mysterious[/b]</u></div></td>

"./*<td><div align='center'>[b]
<font color=white><u></font><font color=red>Drugs Makers</font>[/b]</u></div></td>

*/"<td><div align='center'>[b]
<font color=white><u></font><font color=red>Gambling Central<u/>[/b]</u></div></td><td><div align='center'>[b]
<font color=white><u></font><font color=red>Central<u/>[/b]</u></div></td>
</tr>
<tr>

<td><div align='center'>[b]
<a href='userlist.php'>Users list[b]

<a href='stafflist.php'>Game Name Staff[b]

[url='halloffame.php']Hall of Fame[/url]

<a href='hos.php'>Hall of Shame[b]

<a href='stats.php'>Game Stats[b]

[url='usersonline.php']Users Online[/url]


[/b]</div></td>

<td><div align='center'>[b]
[url='missions.php']Missions[/url]

[url='raffle.php']Raffle House[/url]

[url='polling.php']Polling Station[/url]

[url='StaffApps.php']Appy For Staff[/url]

[url='brothel.php']Brothel House[/url]

[/b]</div></td>

"./*<td><div align='center'>[b]
[url='drugfarm.php']Drug Farm[/url]

[url='drugsmarket.php']Drugs Market[/url]

[url='drugfarm.php?action=premade']Buy Drugs[/url]

[url='drugfarm.php?action=mydrugs']Your Drugs[/url]

[/b]</div></td>

*/"<td><div align='center'>[b]
[url='5050c.php']50/50 Money[/url]

[url='5050p.php']50/50 Points[/url]

[url='lottery.php']Lottery[/url]

[url='crack.php']Crack The Safe[/url]

[url='searchdowntown.php']Search Downtown[/url]

[url='casino.php']Casino[/url]

</div>[/b]</td>

<td><div align='center'>[b]
[url='mailbox.php']Mailbox[/url]

[url='gym.php']Gym[/url]

[url='events.php']Events[/url]

[url='forums.php']Forums[/url]

[url='gamerules.php']Rules[/url]

[url='breport.php']Bug Report[/url]

</div>[/b]</td>
</tr>
</table>";
$h->endpage();
?>
Link to comment
Share on other sites

When a script has an error look at the line number to see whats happening.

In this case line 42

print'

 

is incorrect. print "

 

I would also remove all of these

 

"./*<td><div align='center'> <font color=white><u></font><font color=red>Drugs Makers</font></u></div></td> */

Link to comment
Share on other sites

Those print bits arnt meant to be there...

 

<td><div align='center'>[b]
[url='shops.php']Game Shops[/url]

[url='myshop.php']Your Shop[/url]

[url='playershops.php']Player Shops[/url]

[url='itemsearch.php']Search Player Shops[/url]
';
if($ir['level'] > 20) { echo ('[url='Auction.php']Auction Market[/url]
'); }
[url='itemmarket.php']Item Market[/url]

[url='cmarket.php']Points Market[/url]
</td>
[/b]</div></td>

 

Thats the code section i need help with.

Link to comment
Share on other sites

This has been tested and wokrs.

 

 

<?php
include "globals.php";
$tresder=(int) rand(100,999);
if($ir['jail'] > 0)
{
die("[b]<font color=red size=+1>You are in Jail for {$ir['jail']} more minute(s).

Until you are out you can't view this page</font>[/b]


[url='jail.php']Return to Jail[/url]");
}
if($ir['hospital'] > 0)
{
die("[b]<font color=red size=+1>You are in the Hospital for {$ir['hospital']} more minute(s).

Until you are out you can't view this page</font>[/b]


[url='hospital.php']Return to Hospital[/url]");
}
print "

<center><table width='715' height='385' border='1' cellpadding='2' class='tablejf1'><center></font><font color=red></font>This is your referal link: http://game-name.com/register.php?REF=$userid 

Every signup from this link earns you 30 valuable Points!
<tr background='header.gif'></font><font color=red></font>
<td height='25'><div align='center'>[b]
<font color=white><u></font><font color=red>Market</u></u>[/b]</div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Living Quarters<u/>[/b]</u></div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Cash Industry</u></font>[/b]</u></div>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Dark Side<u/>[/b]</u></div></td></td>
</tr>
<tr>

<td><div align='center'>[b]
[url='shops.php']Game Shops[/url]

[url='myshop.php']Your Shop[/url]

[url='playershops.php']Player Shops[/url]

print'[url='itemsearch.php']Search Player Shops[/url]
";

if($ir['level'] > 20) {
echo '[url="Auction.php"]Auction Market[/url]
'; }
print"
[url='itemmarket.php']Item Market[/url]

[url='cmarket.php']Points Market[/url]
</td>
[/b]</div></td>

<td><div align='center'>[b]
[url='monorail.php']Travel[/url]

[url='houses.php']Houses[/url]<br 
[url='pointbank.php']Points Bank[/url]
</td>
[/b]</div></td>

<td><div align='center'>[b]
[url='bank.php']City Bank[/url]

[url='creditcard.php']Credit Card[/url]

[url='business_view.php']Business listings[/url]

[url='business_create.php']Create a business[/url]

[url='business_home.php']Your business[/url]

[/b]</div></td>

<td><div align='center'>[b]
[url='crystaltemple.php']Points Temple[/url]

[url='hitmanagency.php']Hitman Agency[/url]

[url='marital.php']Marital Agency[/url]

[url='donatorlist.php']View Donators[/url]

[url='gymrecord.php']Gym Record[/url]

[url='games.php']Arcade[/url]

</div>[/b]</td>

</tr>
<tr background='header.gif'>
<td height='25'><div align='center'>[b]
<font color=white><u></font><font color=red>Statistics Dept</u>[/b]</u></div></td>

<td><div align='center'>[b]
<font color=white><u></font><font color=red>Mysterious[/b]</u></div></td>

"./*<td><div align='center'>[b]
<font color=white><u></font><font color=red>Drugs Makers</font>[/b]</u></div></td>

*/"<td><div align='center'>[b]
<font color=white><u></font><font color=red>Gambling Central<u/>[/b]</u></div></td><td><div align='center'>[b]
<font color=white><u></font><font color=red>Central<u/>[/b]</u></div></td>
</tr>
<tr>

<td><div align='center'>[b]
<a href='userlist.php'>Users list[b]

<a href='stafflist.php'>Game Name Staff[b]

[url='halloffame.php']Hall of Fame[/url]

<a href='hos.php'>Hall of Shame[b]

<a href='stats.php'>Game Stats[b]

[url='usersonline.php']Users Online[/url]


[/b]</div></td>

<td><div align='center'>[b]
[url='missions.php']Missions[/url]

[url='raffle.php']Raffle House[/url]

[url='polling.php']Polling Station[/url]

[url='StaffApps.php']Appy For Staff[/url]

[url='brothel.php']Brothel House[/url]

[/b]</div></td>

<td><div align='center'>[b]
[url='drugfarm.php']Drug Farm[/url]

[url='drugsmarket.php']Drugs Market[/url]

[url='drugfarm.php?action=premade']Buy Drugs[/url]

[url='drugfarm.php?action=mydrugs']Your Drugs[/url]

[/b]</div></td>

<td><div align='center'>[b]
[url='5050c.php']50/50 Money[/url]

[url='5050p.php']50/50 Points[/url]

[url='lottery.php']Lottery[/url]

[url='crack.php']Crack The Safe[/url]

[url='searchdowntown.php']Search Downtown[/url]

[url='casino.php']Casino[/url]

</div>[/b]</td>

<td><div align='center'>[b]
[url='mailbox.php']Mailbox[/url]

[url='gym.php']Gym[/url]

[url='events.php']Events[/url]

[url='forums.php']Forums[/url]

[url='gamerules.php']Rules[/url]

[url='breport.php']Bug Report[/url]

</div>[/b]</td>
</tr>
</table>";
$h->endpage();
?>
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...