will this work?

  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

i dont have the right utlitys to test this out so i was wondering if anyone could tell me if it looks clear and would work

PHP Code: [ Select ]
function removeDisMembers($agree, $delete) {
 
if($agree == yes && $delete == yes) {
 
@mysql_query("DELETE FROM $members WHERE disable = \"1\"")
 
or die("Did not exicute please contact the writer at Nytro@aol.com");
 
 
 
echo("All disabled members have been deleted from the database can not be undisabled. Thank your for using my script <br>&copy; 2004+ Nytro@aol.com
 
<center>
 
<a href='main.php'>Return to your console.</a>
 
</center>
 
");
 
}
 
require("functions.php");
 
echo("
 
<form action='$PHP_SELF' method='post'>
 
Are you sure you want to remove all dislabed members from your database?
 
<textarea>If you agree, and exicute no damage can be placed on these scripts you are using these at your own risk.</textarea><br>
 
<input type=radio name=agree value=yes>
 
<input type=radio name=agree value=no>
 
<br>
 
<input type=submit name=delete value=yes>
 
<input type=submit name=delete value=no>
 
</form>
 
 
 
if(submit) {
 
removeDisMembers($agree, $delete);
 
}
  1. function removeDisMembers($agree, $delete) {
  2.  
  3. if($agree == yes && $delete == yes) {
  4.  
  5. @mysql_query("DELETE FROM $members WHERE disable = \"1\"")
  6.  
  7. or die("Did not exicute please contact the writer at Nytro@aol.com");
  8.  
  9.  
  10.  
  11. echo("All disabled members have been deleted from the database can not be undisabled. Thank your for using my script <br>&copy; 2004+ Nytro@aol.com
  12.  
  13. <center>
  14.  
  15. <a href='main.php'>Return to your console.</a>
  16.  
  17. </center>
  18.  
  19. ");
  20.  
  21. }
  22.  
  23. require("functions.php");
  24.  
  25. echo("
  26.  
  27. <form action='$PHP_SELF' method='post'>
  28.  
  29. Are you sure you want to remove all dislabed members from your database?
  30.  
  31. <textarea>If you agree, and exicute no damage can be placed on these scripts you are using these at your own risk.</textarea><br>
  32.  
  33. <input type=radio name=agree value=yes>
  34.  
  35. <input type=radio name=agree value=no>
  36.  
  37. <br>
  38.  
  39. <input type=submit name=delete value=yes>
  40.  
  41. <input type=submit name=delete value=no>
  42.  
  43. </form>
  44.  
  45.  
  46.  
  47. if(submit) {
  48.  
  49. removeDisMembers($agree, $delete);
  50.  
  51. }

thank you
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

You'll have to forgive me

*steps on soap box

It might work, it might not. One wonders what you are trying to do? One also wonders why you don't have the tools to test it?

Change the following for starters:

Find:
exicute

Replace with:
execute

---------------------
Find:
undisabled

Replace with:
undone

---------------------
Find:
Thank your

Replace with:
Thank you

----------------------
Find:
dislabed

Replace with:
disabled


(Spellcheck also works)

*sighs *steps off soap box
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

well what im maken are for clan scripts witch are sciprts that lets someone build a gaming community with no nolage of php. it lets them have a members login system with console, post news edit remove, disalbed, undisale everything you would need to do to run a little site for a gaming clan... my addon will remove disabled members from your database completly for those who want to with out going though myphpadmin.

and to answer why i dont have the right tools is that i dont have a copy of the scripts loaded onto a server.
  • ATNO/TW
  • Super Moderator
  • Super Moderator
  • User avatar
  • Posts: 23456
  • Loc: Woodbridge VA

Post 3+ Months Ago

*sighs again. I think you missed my point. Hopefully, someone else can help you with your code. At the moment, I can't.
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

i under stand what you are saying i was just wondering if there where any aparent errors in my scripting. thank you
  • this213
  • Guru
  • Guru
  • User avatar
  • Posts: 1260
  • Loc: ./

Post 3+ Months Ago

I'm guessing this is what you're trying to do. Put it on a server and try it out:
PHP Code: [ Select ]
function removeDisMembers($agree, $delete) {
 
   if($agree == yes && $delete == yes) {
 
      @mysql_query("DELETE FROM $members WHERE disable ='1'")
 
      or die("Did not execute please contact the writer at Nytro@aol.com");
 
 
 
      echo("All disabled members have been deleted from the database can not be undone. Thank you for using my script <br>&copy; 2004+ Nytro@aol.com
 
<center>
 
<a href='main.php'>Return to your console.</a>
 
</center>
 
      ");
 
   } else {
 
      require("functions.php");
 
      echo("
 
<form action='$PHP_SELF' method='post'>
 
Are you sure you want to remove all disabled members from your database?
 
<textarea>If you agree, and execute no damage can be placed on these scripts you are using these at your own risk.</textarea><br>
 
<input type=radio name=agree value=yes>
 
<input type=radio name=agree value=no>
 
<br>
 
<input type=submit name=delete value=yes>
 
<input type=submit name=delete value=no>
 
</form>
 
      ");
 
   }
 
}
 
if(submit) {
 
   removeDisMembers($agree, $delete);
 
}
 
 
  1. function removeDisMembers($agree, $delete) {
  2.  
  3.    if($agree == yes && $delete == yes) {
  4.  
  5.       @mysql_query("DELETE FROM $members WHERE disable ='1'")
  6.  
  7.       or die("Did not execute please contact the writer at Nytro@aol.com");
  8.  
  9.  
  10.  
  11.       echo("All disabled members have been deleted from the database can not be undone. Thank you for using my script <br>&copy; 2004+ Nytro@aol.com
  12.  
  13. <center>
  14.  
  15. <a href='main.php'>Return to your console.</a>
  16.  
  17. </center>
  18.  
  19.       ");
  20.  
  21.    } else {
  22.  
  23.       require("functions.php");
  24.  
  25.       echo("
  26.  
  27. <form action='$PHP_SELF' method='post'>
  28.  
  29. Are you sure you want to remove all disabled members from your database?
  30.  
  31. <textarea>If you agree, and execute no damage can be placed on these scripts you are using these at your own risk.</textarea><br>
  32.  
  33. <input type=radio name=agree value=yes>
  34.  
  35. <input type=radio name=agree value=no>
  36.  
  37. <br>
  38.  
  39. <input type=submit name=delete value=yes>
  40.  
  41. <input type=submit name=delete value=no>
  42.  
  43. </form>
  44.  
  45.       ");
  46.  
  47.    }
  48.  
  49. }
  50.  
  51. if(submit) {
  52.  
  53.    removeDisMembers($agree, $delete);
  54.  
  55. }
  56.  
  57.  
  • SpooF
  • ٩๏̯͡๏۶
  • Bronze Member
  • User avatar
  • Posts: 3422
  • Loc: Richland, WA

Post 3+ Months Ago

well no, sence i cant edit the page functions.php yet, or i could but i would rather not i just put the functions on the same page. it echos the form when you submit it exicutes the functions. BUT that did help ^^ now it will have a loop tell you do it right :D

Post Information

  • Total Posts in this topic: 7 posts
  • Users browsing this forum: No registered users and 133 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.