Jump to content

DeanWhitehouse

Members
  • Posts

    2,527
  • Joined

  • Last visited

Everything posted by DeanWhitehouse

  1. thats a timestamp format, please use google, and php manual http://uk.php.net/date
  2. you don't need ajax, you just need javascript, something like <script type="text/javascript"> function AddCount() { ?> $i++; mysql_query("UPDATE table SET count='{$i}'"); <?php } </script> <img src="" onClick="AddCount()"> that should do the trick
  3. so you want it for when they on the image to add a count? not when it loads the page with the image?
  4. i didn't know about preg match, i was suggesting replacing the [24] and with just a blank space mad techie has a better solution
  5. okay then you will need a regex, using preg_replace and then you can convert [24] to anything and this will save the result in a string.
  6. i am pretty sure that is kinda bbcode will the start and end tags always be [24]
  7. set a session that contains there level, then check this session and redirect depending on there level.
  8. restarting the computer doesnt delete cookies.
  9. ok, have you cleared the cache, and all the cookies/sessions saved in it?
  10. can you please stop bumping the thread. And when you run the browser again, are you restoring the page . e.g. firefox says restore previus session, and this sets all the sessions as they where when it was closed.
  11. .php database? no such thing(correct me if im wrong) ,also please at least attempt to make the script and ask for help on errors, if you want the script made for you . go to the freelance section.
  12. echo "<OPTION value='$line['dailyNewspaper1']'>$line['dailyNewspaper1']</OPTION>"; that should work
  13. You will have to do the image your self, this is not the freelance section we are here to help not to do it all for you. For registration you will need to decide whether to have it db driven or not , and then make a script from there. <html> <head> </head> <body> <?php if(isset($_POST['login'])) { $username = "username"; $password = "password"; if($username == $_POST['password'] && $password == $_POST['password']) { $_SESSION['login'] = true; } else { echo "Wrong username or password"; } } if(isset($_SESSION['login']) == true) { if(isset($_POST['email']) && isset($_POST['comment'])) { if(!empty($_POST['email'])) { if( !empty($_POST['comment']) { // do stuff with your comment and e-mail here } else { die("Please type a comment."); } } else { die("Please type your e-mail."); } } else { ?> <!-- HTML FORM --> <form action="thispage.php" method="post"> E-mail <input type="text" name="email"> Comment <textarea name="comment" cols="50" rows="10"></textarea> </form> <!-- HTML FORM --> <?php } } else { ?> Please Login <form method="post" action=""> <input type="text" name="uname"/> <input type="password" name="password"/> <input type="submit" name="login" value="Log In"/> </form> <?php } ?> </body> </html>
  14. this is more HTML friendly <html> <head> </head> <body> <?php if(isset($_POST['email']) && isset($_POST['comment'])) { if(!empty($_POST['email'])) { if( !empty($_POST['comment']) { // do stuff with your comment and e-mail here } else { die("Please type a comment."); } } else { die("Please type your e-mail."); } } else { ?> <!-- HTML FORM --> <form action="thispage.php" method="post"> E-mail <input type="text" name="email"> Comment <textarea name="comment"></textarea> </form> <!-- HTML FORM --> <?php } ?> </body> </html>
  15. change error_reporting(E_PARSE); to error_reporting(E_ALL);
  16. ok, well try changing them. $_POST[''];
  17. should you be using http_post_vars? shouldn't it be $_POST[''];
  18. i havent read the whole script , but have u tried putting the message(from, sent,subject etc,) in a while loop?
  19. is_numeric(); is the function to check if the string is numeric, and search the php manual string functions to find one to check for the number in the string.
  20. not this "<OPTION value='$line['dailyNewspaper1']'>$line['dailyNewspaper1']</OPTION>"; this <OPTION value="$line['dailyNewspaper1']">$line['dailyNewspaper1']</OPTION>
×
×
  • 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.