Latest Post

How to check empty or null in Mysql Query?

If you want to check empty or null value with conditional statement like case when and if in table row with Mysql database. you like to check empty or null value form table then you have multiple way check that. first we check empty value with case when statement then following example. <strong>Empty Check:</strong> <pre class="language-mysql"> SELECT (CASE WHEN COALESCE(email,'')!='' THEN email ELSE 'example@gmail.com' END) as test FROM `customers` ---------------------OR---------------------- SELECT (CASE COALESCE(email,'') WHEN '' THEN 'example@gmail.com' ELSE email END) as test FR.....

By Hardik Savani | January 31, 2016 | | 693 Viewer | Category : PHP MySql
READ MORE

How to copy one table data into another table using Mysql Query?

If you are working on php or any php framwork and you want to copy one table into other table by using sql query, so you could do it using simple SELECT and INSERT statement. just you need to think how you can use. In Following example you can see how to fetch data from "post" table and how to insert into "post_copy" table, so basically you have to select field of one that you want to copy and second one give name of table with proper field that you want insert. But don't forgot to give a name of field otherwise it generate error. <pre class="language-mysql"> INSERT INTO `post_copy` (name,sl.....

By Hardik Savani | January 30, 2016 | | 1084 Viewer | Category : PHP MySql
READ MORE

How to add text on image in laravel 5?

if you are use laravel and you want to add text on image or resize, crop image then we can do with "intervention/image" pakacke. you have to just follow few step and you can add text on image. <strong>Step 1 : </strong>you have to add package on your laravel project by using composer like : <pre>composer require intervention/image</pre> <strong>Step 2 :</strong> then you have to add provider path and alias path in config/app.php file like : In $provides : <pre>'Intervention\Image\ImageServiceProvider'</pre> In $aliases : <pre>'Image' => 'Intervention\Image\Facades\Image'</pre> <strong>.....

By Hardik Savani | January 30, 2016 | | 2649 Viewer | Category : Laravel
READ MORE

How to get days difference between two dates in laravel?

Whenever you need to get difference between two dates in date 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 days. In Following example you can see, we have a two dates, first $to variable and second one $from variable. Carbon class diffInDays 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 = \Carbon\.....

By Hardik Savani | January 29, 2016 | | 2227 Viewer | Category : Laravel
READ MORE

How to remove null values from array in PHP?

you have array with null value and you want to remove all null value from that array without loop. you can remove your all null value from array without loop. PHP array_filter function through you can remove all null value, you see following example how to remove null value : <strong>Example:</strong> <pre class="language-php"> $example = array(100, "hardik", null, "hey", NULL, "", 77); $result = array_filter($example, function($value) { return !is_null($value); }); print_r($result); </pre> <strong>Output:</strong> <pre>Array ( [0] => 100 [1] => hardik [3] => hey [5.....

By Hardik Savani | January 28, 2016 | | 1438 Viewer | Category : PHP
READ MORE


Lightbox Nodejs array_map Specific PayPal Terminal Chat jquery.email-autocomplete.min.js Sendgrid Sitemap Mysql Concat Environment gmaps.js toSql oauth Object Cache Calculate HTML to PDF Redirect GuzzleHttp Determine tagsinput.js thujohn/twitter package ANDROID_HOME Frontside Validation PingPong New Features Application Email Old Google OAuth marker Admin Panel xoxco tags input Website Ionic Installation Branch split Carbon public_path Bitbucket Artisan apache2 bootstrap-growl Linux Service Provider Issue Select Query chmod Billing date_format() Jquery Plugin ACL User Select KCFinder Resize Image stevebauman/location composer package bootstrap-multiselect plugin PostgreSQL execute query Elasticsearch ServiceProvider Zip Trigger Permission Tutorial QR Code Now Letter Null Middleware Collapse Import Modal Generate filter XSS Bootstrap show password Plugin Windows Packages Paypal Payment Gateway basename() WHERE Query groupBy() Migration Ckeditor inner join Remote Paypal Integration Custom Command CASE_LOWER POST Ajax Numeric Animation guzzle http client Special Cross Chart Each auth() getQueryLog Link CloudConvert API Last Controluser Attr View Strip Tags Remove Ionic framework Controller SMTP Package Manual throttle Reset Barcode Laravel 5 Node JS Mailchimp API Validation slice() orderBy Parameters Timepicker array_combine mysqld.sock JWT Sort JS refspec Dropbox API filesize() Custom Check Google API Highlight JS File AngularJS Filter Export Prompt modal Gmail upload_max_filesize Rewrite Delete parse Twitter Bootstrap