Jump to content

jitesh

Members
  • Posts

    807
  • Joined

  • Last visited

Everything posted by jitesh

  1. $var = 90; // mins $str = floor($var/60)." hours ".($var%60)." mins";
  2. profiltekst, alder, `by` , mandag, tirsdag, use back tick (`) for database name, table name and field name
  3. Onsubmit event disable textboxes which you do not want to submit using JS. Disabled fields never posted. Like function onevent(){ document.getElementById('textbox1').disabled = true; }
  4. If you have any common file. like as DB connection or Config file which is included in all files Then you can metion. extract($_REQUEST); in first line. This is just temporaly solution.
  5. Yes session_start() creates a session or resumes the current one based on the current session id that's being passed via a request, such as GET, POST, or a cookie.
  6. function print($print) { print $print . "<br>"; }
  7. SELECT * FROM `authors` WHERE `authorlast`IN ('{$_POST['authorlast1']}','{$_POST['authorlast2']}','{$_POST['authorlast3']}');
  8. jitesh

    Numbers

    Something like this <?php $associative_array = array(); $associative_array['a0'] = array( 4, 2, 3, 4 ); $associative_array['a1'] = array( 1, 2, 3, 1 ); $associative_array['a2'] = array( 4, 3, 4, 4 ); $associative_array['a3'] = array( 2, 3, 1, 1 ); $new_array = array(); for($i=0;$i<count($associative_array);$i++){ $new_array = array_merge($new_array,$associative_array['a'.$i]); } sort($new_array); for($i=0;$i<count($new_array);$i++){ echo $new_array[$i]." "; } ?>
  9. jitesh

    Numbers

    Can't you take a associative array ? Then its a way to make it easy.
  10. Check mime content type for a file. string mime_content_type ( string filename )
  11. Throught AJAX you can post data. Just review the example http://www.phpbuilder.com/columns/jon_campbell20070730.php3
  12. Are you connecting to DB properly ? May may be you are getting die with and printed string "my sql error". This is just assumption.
  13. Follow this flow of coding. (1) Login.php file // Fill up login information (2) intermediate_action.php // Here keep an intermediate action file which contains database operations , Login check , Set of session variables etc... (3) After step 2 redirect to other page like as user_account.php etc. Check the above way.
  14. strtotime does not understand your "date type" given as input.
  15. <?php $sql = "INSERT INTO outcomes( outcomeID, jobID, theOutCome, outcomeDate, outcomeTime, userID ) VALUES ( '','".$jobCallID."','".nl2br($outcomeString)."','".$callDate."','".$callTime."','.".$UsID."')"; ?>
  16. In php.ini change maximum_execution_time (0 for unlimited). Restart webserver and check.
  17. When you are saving data into db you need to use this function. INSERT INTO `table` (`id`,`info`) VALUES (1, nl2br(' ...... ')); nl2br is a PHP function.
  18. Temporary mention "set_time_limit(0);" in first line of the code and check.
  19. http://www.phpfreaks.com/forums/index.php/topic,174937.msg774153.html
  20. $minimum_count = 0; $maximum_count = 0; $spread = 0; if (count($tags)) { $minimum_count = min(array_values($tags)); $maximum_count = max(array_values($tags)); $spread = $maximum_count - $minimum_count; }
  21. Rename the myTruncate with something else Like : function myTruncate_($string, $limit, $break=".", $pad="..."){ ......... ......... } $short_omschrijving = myTruncate_($omschrijving, 300, " ");
  22. Before using array its a good habit to define a variable as an ARRAY Example : function tag_info() { $result = mysql_query("SELECT * FROM tags GROUP BY tag ORDER BY count DESC"); $arr = array(); while($row = mysql_fetch_array($result)) { $arr[$row['tag']] = $row['count']; } ksort($arr); return $arr; }
  23. <?php echo "<TABLE BORDER=\"1"\ WIDTH=\"988"\ > <TD> <TABLE BORDER=\"1"\ RULES=\"rows"\ WIDTH=\"190px"\ ALIGN=\"center"\ > <TR> <TD CLASS=\"theadings"\ ><CENTER><B>General</B></CENTER></TD> </TR> ............................................... ........................................................ ........................................................ ?>
×
×
  • 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.