
Search In
JavaScript Comparing For and While Loop
Both the loops are similar in some ways, like both are used for repeated execution of statements as well as execution are done till the condition is true.
For loop and while loop they differ by the syntax as,
PHP have some magic methods that you can use in OOP (Object Oriented Programming). All the magic functions must be identified with twice underscores (__) prefix and they work as interceptors that will run when certain required conditions are met.
F
Hello Guys
Here, I write blog for sort JSONArray using alphanumeric string.
Create JSONArray below :
JSONObject jsonObjupdate = JSONFactoryUtil.createJSONObject();
JSONArray jsonArrayupdate=JSONFactoryUtil.createJSONArray();
Here I have created Checkbox function in android. In android CheckBox is a type of two state button either checked or unchecked. We can use checkbox to activate/deactivate the specific action. In the below code example, I have described how to make c
Error logging handler is defined or registered in the app/start/global.php. We will define or configure logger
to use a single log. In laravel we have MONOLOGY logging library. By using Monolog offers we will use n number of handlers.
Example
$log
There are n number of functions in laravel 4.x which is used to define path that are
app_path:
app_path is a function which is used to get the fully qualified path of the app directory.
Example:
$path = app_path();
base_path:
base_path is a fu
There are n number of functions of strings in laravel 4.x which is used to perform action in string that are
camel_case:
camel_case is a function which is used to convert the given string to camelCase.
Example:
$camel = camel_case('foo_bar');
Res
The Carbon class is inherited from the PHP DateTime class.
Example:
<?php
class Carbon extends \DateTime
{
// code here
}
?>
There are n number of situation when we want to get the 1 day or 2 days old data. For this we will do calculati
Hello readers, today we will discuss about "Calculating the difference between two dates in PHP".
For example, we have 2 dates and we wants to find the difference between them in php so we can use the below code:
$date1 = "2007-03-24";
$date2 = "20
Laravel 4.x provide n number of services to solve basic issues. By using Laravel 4.x we will easily set a default attribute for a Laravel/Eloquent model.
To achieve this we have to define value like below example:
Example:
protected $defaults = ar