PHP | header() function By sending the headers bellow, we change the browser’s default cache settings. We can override any of those settings and force the browser to not cache. In this code we just …

Last updated 5 years, 7 months ago | 1263 views

Tags:- PHP

Mysql | Trigger The trigger can be defined as a database object just like a stored procedure. It is a set of actions that fires automatically when an event occurs in a database.   Triggers …

Last updated 5 years ago | 1259 views

Tags:- MySQL

PHP | Check data type in php | gettype() | var_dump() By using gettype() function we can check the data type of a variable. we can also use var_dump() function for the same.   gettype() <?php echo …

Last updated 5 years ago | 1254 views

Tags:- PHP

Django | order_by query set, ascending and descending order_by() The order_by function is used to sort the result-set in ascending or descending order. Ascending Order The order_by function sorts the records in ascending order by …

Last updated 3 years, 2 months ago | 1251 views

Tags:- Django

Googlebot | What is a robots.txt file? A robots.txt is a simple text file that can be created by a notepad editor. This file is used for search engines, which provide instructions to search engines on how …

Last updated 5 years ago | 1250 views

Tags:- robots_txt

PHP | Count number of elements in an array There are two ways to find the number of elements in an array: 1. sizeof($arr), This function is an alias of count() echo sizeof($arr); 2. count($arr) echo …

Last updated 5 years, 7 months ago | 1247 views

Tags:- PHP

PHP | max_execution_time directive in php.ini file By changing the value of  max_execution_time in the php.ini file max_execution_time = 30; // in second   By default, the maximum execution time for PHP scripts is set to …

Last updated 5 years, 7 months ago | 1246 views

Tags:- PHP

PHP | How to convert a string to an array? string to array There is a function in PHP called explode() which is used to convert any string to an array.    <?php $str = …

Last updated 5 years ago | 1246 views

Tags:- PHP

By using following query we can find out the nth largest salary from employees table. SELECT salary FROM `employees` ORDER BY salary DESC LIMIT 1 OFFSET n-1 In the above query n is replaced by …

Last updated 5 years ago | 1243 views

Tags:- SQL MySQL

SQL | Compare timestamp with date only Timestamp holds Date and Time both with 19 characters. To filter table record with the only date parameter can be achieved by SQL DATE() function. Consider the Employee table …

Last updated 3 years, 11 months ago | 1241 views

Tags:- SQL MySQL

PHP | What are superglobal/global variables? Superglobal is out of scope limitation. These variables can be accessed from any function, class, or file without doing anything special such as declaring any global variable, etc. These …

Last updated 5 years ago | 1236 views

Tags:- PHP

PHP | How to convert an array to a string? array to string By using implode function we can convert any array to string.  In implode function first parameter is separator which specifies what to …

Last updated 5 years ago | 1223 views

Tags:- PHP

PHP | Increase default session  timeout The "session.gc_maxlifetime" is use to modify the default timout of session. server should keep session data for AT LEAST 1 hour by using the below code. It increase session …

Last updated 5 years ago | 1218 views

Tags:- PHP

Jquery | attr | Get HTML attribute's value You can get the value of an attribute for the first element in the set of matched elements using the .attr() function.   Return the value of …

Last updated 4 years, 5 months ago | 1216 views

Tags:- JQuery

PHP | Upload File By using move_uploaded_file() function we can upload file in PHP.The move_uploaded_file() function moves an uploaded file to a new location. This function returns TRUE on success or FALSE on failure. move_uploaded_file(file,newloc) …

Last updated 5 years ago | 1214 views

Tags:- PHP