Latest Post

laravel 5 change date format using carbon example

Sometimes you require to change date format in your laravel app. we have to use Carbon class for change format in laravel, because it provide many date function for like change date formate, count diffrence between two dates in days etc. So, Basically i am going to show you change date format using Carbon. we will use createFromFormat() and format(), createFromFormat() will take two argument first give format of date and second one date and format() take one argument give formate as you want. you can see bellow example: <strong>Example:</strong> <pre class="language-php"> $date = date('Y-m-d H.....

By Hardik Savani | February 16, 2016 | | 5165 Viewer | Category : PHP Laravel

Laravel 5.2 and AngularJS CRUD with Search and Pagination Example.

Now i show you how to create CRUD(Create, Read, Update, Delete) using AngularJS and Laravel 5. In Following step by step you can create web application of create, edit, delete, lists, search with pagination of items modules. In this post through you can make simple crud, search and pagination module and easily use in your laravel project. I am going to show preview of items module that we will do using angularJS and Laravel 5.2. <strong>Preview</strong> <img src="/upload/laravel-angular.png" width="100%" style="border:2px solid cadetblue" /> <strong class="step">Step 1: Create items table an.....

By Hardik Savani | February 15, 2016 | | 126611 Viewer | Category : PHP Laravel AngularJS

How to get hours difference between two dates in laravel?

Whenever you need to get difference between two dates in hours in laravel 5 then you can get easily using Carbon. Laravel by default provide Carbon class. Carbon class throught you can calculate difference between two dates in hours. In Following example you can see, we have a two dates, first $to variable and second one $from variable. Carbon class diffInhours function using you can get difference between two dates. I hope you will find your solution. <strong>Example:</strong> <pre class="language-php"> $to = \Carbon\Carbon::createFromFormat('Y-m-d H:s:i', '2015-5-5 3:30:34'); $from = \Carb.....

By Hardik Savani | February 13, 2016 | | 3779 Viewer | Category : Laravel

How to add prefix in each key of PHP Array?

Whenever you require to add one character or more to each and every key of array then most of the people would like prefer add key using for loop or foreach loop. But we can do this without using any kind of loop. using array_combine(), array_keys() and array_map() through we can add prefix on each key of array, In Bellow example you can see how to use both function together and add faster way to add prefix of every item key: <strong>Example:</strong> <pre class="language-php"> $myArray = ['0'=>'Hi','1'=>'Hello','2'=>'Hey']; $myNewArray = array_combine( array_map(function($key){ return 'a.....

By Hardik Savani | February 13, 2016 | | 4095 Viewer | Category : PHP

How to get minimum key value of array in PHP?

Sometimes, you need to get minimum key value of your array but you try to get with loop and any function etc, but in bellow example you can see we can get smallest key value from our php array by using min() and array_keys(). So, let's try to use in your code this way: <strong>Example:</strong> <pre class="language-php"> $myArray = ['2'=>'Hey','4'=>'Hello','1'=>'Hi','3'=>'GH']; $new_key = min(array_keys($myArray)); $new_val = $myArray[$new_key]; print_r($new_val); </pre>

By Hardik Savani | February 12, 2016 | | 701 Viewer | Category : PHP

Issue Socialite Top Import Enable Database Seeder Plugins roumen/feed package JS refs PHP ANDROID_HOME strpos typed.js plugin Sql CSS tagsinput.js Laravel Builder New Features Scroll Loop Letter Form Validation laravel-elixir Sort QR Code Datepicker HTML characters Google Chart Mail Ubuntu XSS jQuery Captcha code HTML to PDF CASE_LOWER API Determine gulp Version date_format() Composer Folder Key Constraint xoxco tags input Specific Inserted Id basename() Packages Object file_exists Terminal refspec Automatically ppa Progress Bar Laravel 5.4 Percentage Special Mailgun API Where Not In Query Payment Gateway Controluser Language Popup Box milon/barcode validator.js bootstrap-growl Google OAuth Query npm Count Sortable csrf_token Recursive Dynamic Dependant Dropdown Run Project COUNT() Server lowercase Key Date Format Mediafıre API Accordion guzzle http client clockface plugin Codeigniter 3 Delete Ajax Request AngularJS Rewrite RSS hasTable Empty Update Chat ajaxStart Eloquent-Sluggable Package Record Technology Linux Bootstrap-lightbox Plugin league/flysystem-dropbox Codeigniter Convert whitespace Website Trigger Components & Slots Mysql Concat Sitemap Controller clipboard.js strtolower Example Fetch Admin Panel Value stevebauman/location composer package GuzzleHttp 404 error page Select pop() ID preg_match glob AngularJS TrustAsHTML Filter uppercase CRUD inner join Check Executed Configuration Frontside Validation toastr js Source Code split API Branch intervention/image Old Form JS Plugin php.ini Remove Gmail Contact US Form clearInterval() Paypal Payment Gateway IP