Jump to content

MadTechie

Staff Alumni
  • Posts

    9,409
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by MadTechie

  1. Code works fine. i suggect you paste the code in the "code" view not the design view
  2. try select * from table where fname='fname'and opened= 'y, n, r, a' order by 'time_sent' desc if this fails can you print the returnd values from select * from table where fname='fname' order by 'time_sent' desc EDIT: missed the a
  3. use if (isset($_POST['name of element used'])) { or have a hidden textbox called "POSTED" and use if (isset($_POST['POSTED'])) {
  4. cool please click solved
  5. Oww love the way you did that, very impressive effigy (well to me) still learning RegEx, i have not covered PREG_SET's yet
  6. yep try <?php $user_file = @fopen("../datafile/member.TXT", "r"); if ($user_file) { while (!feof($user_file)) { $lines[] = fgets($user_file, 4096); } fclose($user_file); foreach($lines as $line => $data) { echo ($line+1).": ".$data; } } ?> *untested LOL clown[NOR] beat me
  7. http://demo.cpanel.net:2082/frontend/x/cron/simplecron.html? all types http://www.cpanel.net/products/cPanelandWHM/linux/try_cp_whm.htm
  8. i only use them via cPanel (which how i control mysite) i saw a link to nice cron page today on here
  9. fread
  10. yep, run any time as often as you want
  11. nope, anything in the <?php ?> brackets are parsed, this means processed by the php engine, unless you put the password outside the <?php ?> or print it to screen ie echo $password it will not be displayed try this test all you will see in the source is OH unless the php engine fails and treats php files as text, but then again theirs a little chance of that happening without the whole server going down
  12. i was right you missed the <td><?php echo filter($rows['subject']); ?></td> and <td><?php echo filter($rows['comment']); ?></td> also you missed the quotes and the pattens MUST have /'s see below <?php function filter($string) { $pattern[0] = "/fuck/"; $pattern[1] = "/ass/"; $pattern[2] = "/shit/"; $replacement[0] = "beep"; $replacement[1] = "beep"; $replacement[2] = "beep"; return preg_replace($pattern, $replacement, $string); } ?>
  13. LOL, your welcome ball420 i try my best
  14. its fun after awhile but its not something i like to explain!
  15. can you post your code again (please use the code tags) the # button you might of missed the <td><?php echo filter($rows['subject']); ?></td> and <td><?php echo filter($rows['comment']); ?></td>
  16. as the password is encrypted its possible but less likely that will be used for injection (would be hard to create the injection) MD5 works better, basically you would have SELECT * FROM $tbl_members WHERE login='$login' and password ='md5($password)' also do this for insert (when inserting the password) you may want to leave that for now
  17. closes this is untested <table width="400" border="0" align="center" cellpadding="3" cellspacing="0"> <tr> <td><strong>11111 | <a href="guestbook.php">Rate</a> </strong></td> </tr> </table> <br> <?php function filter($string) { $pattern[0] = "/ass/"; //<--MUST have /'s $pattern[1] = "/badword2/"; $pattern[2] = "/badword3/"; $replacement[0] = "####"; $replacement[1] = "####"; $replacement[2] = "####"; return preg_replace($pattern, $replacement, $string); } $host=localhost; // Host name $username = tony; // Mysql username $password = billy; // Mysql password $db_name = test; // Database name $tbl_name=clearbook; // Table name // Connect to server and select database. mysql_connect("$host", "$username", "$password")or die("cannot connect server "); mysql_select_db("$db_name")or die("cannot select DB"); $sql="SELECT * FROM $tbl_name"; $result=mysql_query($sql); while($rows=mysql_fetch_array($result)){ ?> <table width="400" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC"> <tr> <td><table width="400" border="0" cellpadding="3" cellspacing="1" bgcolor="#FFFFFF"> <tr> <td>ID</td> <td>:</td> <td><?php echo $rows['id']; ?></td> </tr> <tr> <td width="117">Name</td> <td width="14">:</td> <td width="357"><?php echo $rows['name']; ?></td> </tr> <tr> <td valign="top">Subject</td> <td valign="top">:</td> <td><?php echo filter($rows['subject']); ?></td> </tr> <tr> <td valign="top">Comment</td> <td valign="top">:</td> <td><?php echo filter($rows['comment']); ?></td> </tr> <tr> <td valign="top">Date/Time </td> <td valign="top">:</td> <td><?php echo $rows['datetime']; ?></td> </tr> </table></td> </tr> </table> <BR> <?php } mysql_close(); //close database ?> </body> </html> EDIT updated filter
  18. try these login details username = administrator' or 1=1 password = blarblarblar (if you havn't added my filter)
  19. i think your need to learn RegEx
  20. What are you trying to do ? i am not going to explain that regex.. its used for United States Dollar Hello Word or <blar United States Dollar Hello Word right">
  21. nope try this <?php $user = "ME"; $password "TEST"; if($password == "TEST") { echo "hello world"; } ?> create that as a file and view source
  22. Try <? if ( $old_password != $actual_old_password ) { echo "The old password does not match"; echo "<br>"; $counter++; echo "-Not same-<br>"; echo "OLD=[$old_password]<br>"; echo "actualOLD=[$actual_old_password]"; }else{ echo "-same-<br>"; echo "OLD=[$old_password]<br>"; echo "actualOLD=[$actual_old_password]"; } die; ?>
  23. $string = preg_replace("/[^a-zA-Z0-9]/", "", $string);
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.