-
Posts
60 -
Joined
-
Last visited
Everything posted by JohnTipperton
-
Show Time Difference Bet Now And Another Auto Updated
JohnTipperton replied to Manhag's topic in PHP Coding Help
you can also use meta to refresh the page. <meta http-equiv="refresh" content="10"> -
Show Time Difference Bet Now And Another Auto Updated
JohnTipperton replied to Manhag's topic in PHP Coding Help
you need to use AJAX to be able to auto update it try this link http://stackoverflow.com/questions/8197487/javascript-auto-update -
here is a list of function you could use is_bool() - Finds out whether a variable is a boolean is_float() - Finds whether the type of a variable is float is_numeric() - Finds whether a variable is a number or a numeric string is_string() - Find whether the type of a variable is string is_array() - Finds whether a variable is an array is_object() - Finds whether a variable is an object
-
Help To Fix Image Resize To Save To Server
JohnTipperton replied to AdSpace's topic in PHP Coding Help
do you save the file in ftp or database? -
Trouble Connecting To My Sql Database?
JohnTipperton replied to codingbenn's topic in PHP Coding Help
i see what about checking the database name.. -
Using Php To Insert Into Database, No Data Going
JohnTipperton replied to neverforget98's topic in PHP Coding Help
no problem mate -
Trouble Connecting To My Sql Database?
JohnTipperton replied to codingbenn's topic in PHP Coding Help
try to check in phpmyadmin if the database exist. -
My Site Requires The .php After Every Page?
JohnTipperton replied to calamityismouton's topic in PHP Coding Help
use mod rewrite via .htaccess -
Using Php To Insert Into Database, No Data Going
JohnTipperton replied to neverforget98's topic in PHP Coding Help
$con = mysql_connect("localhost","mysql_user","mysql_pwd");if (!$con) { die('Could not connect: ' . mysql_error()); } -
Using Php To Insert Into Database, No Data Going
JohnTipperton replied to neverforget98's topic in PHP Coding Help
try this $result="INSERT INTO users(username,passwordHash,real_name,position,email,altemail,hnumber,mnumber,sysusername,sysnumber,nondisclosure,properconduct,termsofuse,perms) VALUES('$username','$passwordHash','$real_name','$position','$email','$altemail','$hnumber','$mnumber','$sysusername','$syspassword','$nondisclosure','$properconduct','$termsofuse','$perms')"; mysql_query($result,$con); the $con is the connection from the database its up to you on how to declare it -
Using Php To Insert Into Database, No Data Going
JohnTipperton replied to neverforget98's topic in PHP Coding Help
you use only mysql_query without a connection to database like using mysql_connect -
try to check this one http://khtml2png.sourceforge.net/ it allows you to create screenshots of webpage.
-
After 3 Fail Login Attemp User Block For 3Mins
JohnTipperton replied to daikumi's topic in PHP Coding Help
well if you are running out of time try to check this page http://codereview.stackexchange.com/questions/7501/login-validation -
your code seems ($_POST['submit']) declared twice what about putting it once.
-
Clean Urls - Replacing '%20' With A '-' Help!
JohnTipperton replied to SimonBruce's topic in PHP Coding Help
<a href="article.php/<?php $news->Title()?>"> you should put echo to <?php echo $news->Title()?> -
Update Database - Error - Please Help!
JohnTipperton replied to lukedouglas98's topic in PHP Coding Help
can you use the [code}[/code]. so we can see clearly. -
Alternating Style While Fetching Database Info
JohnTipperton replied to MrXander's topic in PHP Coding Help
what about trying to use % 2 <?php $x=0; while($rowData=mysql_fetch_array($rs)) { $x=$x+1; if ($x % 2) { echo '<tr>'; }else{ echo '<tr class="alt">'; } ?> -
yes of course values need to be validated i just gave him an idea on how to do it.
-
it would be more readable if you use {code][/code] tags
-
Query For Multiple Foreign Key To Same Table
JohnTipperton replied to robk27's topic in PHP Coding Help
can you provide your .sql script ill do the query. -
$needsip = $_POST['ip']; change it to $needsip = mysql_real_escape_string($_POST['ip']);
-
you are trying to create an advance search right. so first create an selectbox field with 4 options and a text box the following name in the option value should be the exact name in the database field <form method="post"> <select name="selecting" id="selecting"> <option value='Classtype' selected="selected">Class Type</option> <option value='Studentname'>Student name</option> <option value='Studentemail'>Student email</option> <option value='Studentgender'>Student gender</option> </select> <input type="text" name="textsearch" value=""> <input type="submit" value="Search"> </form> in your query it should be like this $Searchfield=$_POST'textsearch'] // assuming this is the text search you input $selection = $_POST['selecting']; // assuming this is the selected value in the option box in step 1 $SQL = "Select * from tblstudent Where ".$selection." LIKE '%".$Searchfield."%'"
-
Give Same Rank Where Points Are The Same
JohnTipperton replied to johnnyd1963's topic in PHP Coding Help
what about using rank() function in a query. or try to use my sample query SELECT first_name, age, gender, @curRank := @curRank + 1 AS rank FROM person p, (SELECT @curRank := 0) r ORDER BY age;