-
Posts
2,527 -
Joined
-
Last visited
Everything posted by DeanWhitehouse
-
thats a timestamp format, please use google, and php manual http://uk.php.net/date
-
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
-
so you want it for when they on the image to add a count? not when it loads the page with the image?
-
good, click topic solved at the bottom.
-
could be your charset? are you using utf-8
-
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
-
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.
-
i am pretty sure that is kinda bbcode will the start and end tags always be [24]
-
are u looking for bbcode?
-
set a session that contains there level, then check this session and redirect depending on there level.
-
solved ?
-
restarting the computer doesnt delete cookies.
-
ok, have you cleared the cache, and all the cookies/sessions saved in it?
-
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.
-
.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.
-
solved?
-
[SOLVED] auto fill drop down lists...help?
DeanWhitehouse replied to TheStalker's topic in PHP Coding Help
echo "<OPTION value='$line['dailyNewspaper1']'>$line['dailyNewspaper1']</OPTION>"; that should work -
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>
-
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>
-
change error_reporting(E_PARSE); to error_reporting(E_ALL);
-
ok, well try changing them. $_POST[''];
-
should you be using http_post_vars? shouldn't it be $_POST[''];
-
[SOLVED] Why is everything being posted twice!?
DeanWhitehouse replied to spiceydog's topic in PHP Coding Help
i havent read the whole script , but have u tried putting the message(from, sent,subject etc,) in a while loop? -
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.
-
[SOLVED] auto fill drop down lists...help?
DeanWhitehouse replied to TheStalker's topic in PHP Coding Help
not this "<OPTION value='$line['dailyNewspaper1']'>$line['dailyNewspaper1']</OPTION>"; this <OPTION value="$line['dailyNewspaper1']">$line['dailyNewspaper1']</OPTION>