I have this.
Code: function DropUser($duser_id, $user_email, $user_username) {
if(isset($_SESSION['admin_username']) && isset($_SESSION['admin_id']) && isset($_SESSION['admin_session_key'])) {
$this->duser_id = mysql_real_escape_string(trim(addslashes(strip_tags(is_numeric($duser_id)))));
$this->user_email = mysql_real_escape_string(trim(addslashes(strip_tags($user_email))));
$this->user_username = mysql_real_escape_string(trim(addslashes(strip_tags($user_username))));
if(!empty($this->duser_id) && !empty($this->user_email) && !empty($this->user_username)) {
$this->dropusersql = "DELETE FROM `members` WHERE `members`.`user_id` = '$this->duser_id' AND `members`.`username` = '$this->user_username' AND `members`.`emailaddress` = '$this->user_email' LIMIT 1";
$this->run_dropusersql = mysql_query($this->dropusersql) or trigger_error('Query failed: ' . mysql_error(), E_USER_ERROR);
$this->removecomplete = '<font color="green"> - The user you select was removed.</font>';
return($this->removecomplete);
} else {
$this->emptyfields = "<font color='red'> - You have left mandatory fields empty.</font>";
return($this->emptyfields);
}
} else {
header('Location: login.php');
}
}
(Part of a class). I get the print back (<font color="green"> - The user you select was removed.</font>) but the query isnt deleting the row.
Many thanks,
in php, link returns to the line
When I add a link in a php page, the link word returns to the line (as a would do)Example:<a href="#">like</a></td> <td><a
selectbox+database connection retrive problem
Code: [Select] <tr> <th align="left" scope="col"><span class="style2 style8">Features
Using CSS to format MySQL query
Hi,If i want to have a news page on my site, which displays all records of a table in descending order by date I am using the below code. I can display it all in a big table but this is a bit boring.
ECC6 - Single sign-on
We are in the process of upgrading to ECC 6 which will support single sign on with user passwords aligned by our active directory to the same as those used to access the Network. My query is that we
Confused with Loop
guys, i got confused with Looping...this is the caseI have 3 stocks, let say "Stock A", "Stock B", "Stock C" and the owner of each stock A --> Mr.Jamesstock B
How to show a complete textarea ??
I enter Client Case Notes notes in a textarea field on a PHP form. The field is 5 rows deep and 70 chars wide , using the scroll bar to see beyond 5 lines.After entering notes, I want to echo or print
Display thumbnails as square while retaining aspect ratio
I am trying to figure out a way to make an image display as a square, for example 80x80 pixels, when the source file is rectangular.The catch is that I want the image to look normal (not squished) so
php wont update my db
hello,sorry for posting in mysql forum but i dont know where exactly is the problem but here is the linkhttp://www.phpfreaks.com/forums/index.php/topic,272737.0.htm
preg_replace question
Hello!!I hope someone can help me with preg_replace.I load two tables from an external website, now I would like to highlight a complete tr (background color) if there is a td with a known string in
how to read and write into a word document using php...?
hi,I need,reading and writting into a word document using php.Thank u inadvance,Madhu