Automatic VIP after calling

Status
Not open for further replies.
Does this work with Desire Edit of UberCMS compatible with Phoenix?
 
A way to make this script better is so that it only works if its been accessed via a click from an external page/redirect from another website - this'd stop people just typing in "page.php" into their browser.
 
Does this work with Desire Edit of UberCMS compatible with Phoenix?

It works with everything.


Hmm thats not good!

<?php
define('USERNAME_REQUIRED', TRUE);
define('ACCOUNT_REQUIRED', TRUE);
include('global.php');
include('config.php');
define("THIS_SCRIPT", 'vip');
$username = $core->EscapeString($_SESSION['username']);
$query = "UPDATE users SET vip='1' WHERE username = '".$_SESSION['username']."' ";
$query = "UPDATE users SET rank='2' WHERE username = '".$_SESSION['username']."' ";
mysql_query($query) or die (mysql_error());
?>

Fixed by Dylan "Dylz"
No, you didnt do it right. How i did it was right, So don't try to make my **** better if you can't dylan.
 
$username = $core->EscapeString($_SESSION['username']);
$query = "UPDATE users SET vip='1' WHERE username = '".$_SESSION['username']."' ";
$query = "UPDATE users SET rank='2' WHERE username = '".$_SESSION['username']."' ";

Why use $username = blabla when your just getting it from the session anyway? geez.
 
$username = $core->EscapeString($_SESSION['username']);
$query = "UPDATE users SET vip='1' WHERE username = '".$_SESSION['username']."' ";
$query = "UPDATE users SET rank='2' WHERE username = '".$_SESSION['username']."' ";

Why use $username = blabla when your just getting it from the session anyway? geez.

Just be happy it works. I'm using this and it works perfect.
 
May I say something. Some of the Ragezoners can code. Looks especially to Joopie. But most of them not. We are just learning it and like it says it's a simple script. Some guys who said this sucks can't even code theirself why should they blame us? Joopie or some coders who can code may blame they know what coding is.
 
Last edited:
Well, I got haters like MerijnZ. Trying to say i cant code, But I'm just a beginner? Atleast it's working. And that's the whole point.
 
PHP:
$query = "UPDATE users SET vip='1', rank='2' WHERE username = '".$_SESSION['username']."' ";

Hey,

There is no need for 2 queries? You can just do the above as far as I can see with one less query.

Regards,
Crago
 
I dont come here often, in fact this is the first time ive posted in a few months, I have a paypal ipn system i posted way back, realised it and stuff. dunno if it will be a help to anyone, its in my old threads somewhere
 
This code totally Fail, what if iam staff rank 6 and i want buy vip ?! if i used this code my rank will be go away to be 2. you got a code working for staff too please ?

thank you
 
Status
Not open for further replies.
Back