Jump to content
MakeWebGames

[mccode] Close page system


Silver
 Share

Recommended Posts

Close Page System

Allows the owner to close any page in the game, and set a reason for the page being closed. Good to use for:

Pages under construction

Pages with bugs

Pages off limits

Go into admin.php (or the file for the owner panel).

 

Find:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Underneath add:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Find:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Underneath add:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Find:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Underneath add:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Open header.php

 

Find:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Underneath add:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Insert this SQL into your database:

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

If you need help with this contact me on msn: [email protected]. If there are any bugs pm me!

Enjoy!

Link to comment
Share on other sites

  • Replies 64
  • Created
  • Last Reply

Top Posters In This Topic

Re: [Free v1] Close page system

Seems complicated. I just open the page and add this at the top

if ($ir['user_level']) != 2)

{

print "This Page is Closed while some bugs are worked out."; exit;

}

Link to comment
Share on other sites

Re: [Free v1] Close page system

yeah i know how to make it ver 2 i did all of it but the only thing stoping me is the part for the header that the part the is messing up it says not a valid mysql resouce i have done evey thing but get the part in the header too work

Link to comment
Share on other sites

Re: [Free v1] Close page system

$close=mysql_query("SELECT * FROM closedpages WHERE url=$page",$c);

change that to

$close=mysql_query("SELECT * FROM closedpages WHERE url=$page",$c) or die(mysql_error());

then post back to me the error you get, i think its cos u need '' around $page

like '$page'

Link to comment
Share on other sites

Re: [Free v1] Close page system

now i get this error

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '/index.php' at line 1

Link to comment
Share on other sites

Re: [Free v1] Close page system

when i do that i get this error

Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/bling/public_html/header.php on line 307

Link to comment
Share on other sites

Re: [Free v1] Close page system

well if anyone can get that part of the header two ver2 let me know be cuz i tryed all kinds of diff stuff and i have a lot of ver 1 mod that i made in two ver two it easy to do it it just this one that i am have am having problems with

Link to comment
Share on other sites

Re: [Free v1] Close page system

Silver - Your mods have working SQL but there is quite a lot of severe errors. I'll name a few

1) Admin Panel functions (when you open a page it shows close page)

How: When you set the functions they correct it to the function "closepage", rename it to "open" and it should work.

2) Submitting open page

How: you setup a $_POST['url'] in the form, but you wrote in the query DELETE FROM closepages WHERE id={$_POST['id']} - posted id (not existed) so replace the {$_POST['id']} with {$_POST['url']}

3) Connections

It automaticly selects, what if no queries then it makes a long text error causing lots of stress in for the players and others.

And a few more..

I myself have infact fixed all the bugs in the code, For assistance ask Silver (if he has fixed) or me.

Link to comment
Share on other sites

Re: [Free v1] Close page system

yeah kyle i dont think you did but ok the part in the header is just a bitch for ver 2 me and silver try on it and i had 5 of my buds helping with it to i have one recoding it for me but if you say you did ok :-D :evil: :roll:

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.

 Share


×
×
  • Create New...