Latest Post

PHP: How to count files in folder?

In PHP, you are work on php and you want to need display count number of files in specific folder then you do, glob() through you count number of file are there in specified folder. now in following example you can see "/var/www/test" in this folder, count how many files are there in that folder. glob function take a two argument first one for directory or folder path and second argument for filter. Filter means if you pass '*' then it will count all type of file, i mean all extension, but if you need to count just text file then you can put like '*.txt'. That't it, if in your directory, func.....

By Hardik Savani | February 4, 2016 | | 2750 Viewer | Category : PHP

How to find day from specific date in PHP?

Whenever you need to det day like Monday, Tuesday etc from full date. i mean you have any specific date like "2015-10-10" and you want to get day then you can do in both way first using strtotime() and second using DateTime object. In Following example you can see i give you both way to get day from your date. now i added format 'l' so it will return full name of day like "Tuesday", but if you want to get short name of day then you can change format like "D". <pre class="language-php"> // Using strtotime() $specificDate = strtotime('2016-2-3'); $specificDate = date('l', $specificDate); var_d.....

By Hardik Savani | February 3, 2016 | | 878 Viewer | Category : PHP

How to push item to 0 index or first of $scope object in AngularJS?

you are working on angular JS and you wanted to add item on top of array, i mean you need to add 0 index of $scope array then you can do. in following example you can see how to do.if you want to push first then you have to use splice() instend of push(). <strong>Example:</strong> <pre class="code language-html"> <html> <head> <title>Angular JS</title> <script src=""></script> <script src=""></script> <script&.....

By Hardik Savani | February 2, 2016 | | 1905 Viewer | Category : JSON AngularJS

How to increment or decrement a column value in laravel?

Whenever you need to increment or decrement value of column in database, then you do not need to first fetch that record and then update, so that way we will make long code and very hard code, so basically you can increment and decrement by using increment() and decrement() statment of laravel query builder. If you want to increment or decrement opration using update() method of laravel query builder then you also do that, in following example i am showing you how to increment and decrement value of column in table by using increment(), decrement() and update(). <pre class="language-php"> na.....

By Hardik Savani | February 2, 2016 | | 12715 Viewer | Category : Laravel

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

Some time when you are open any link your website then browser display following massage <h2 style="margin:0px;padding:0px;">Not Found</h2> <span style="margin:0;padding:0;">The requested URL /test.html was not found on this server.</span> <span style="margin:0;padding:0;">Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.</span><br /> this problem fix by .htaccess write following code in your .htaccess file <pre class="language-mysql"> RewriteEngine on <IfModule mod_rewrite.c> RewriteBase / RewriteCond %{REQUEST_FILENAME} !-f Rewrit.....

By Hardik Savani | February 1, 2016 | | 1520 Viewer | Category : .htaccess

404 error page phpword Executed Email MassAssignmentException virtual host QR Code Site Jquery UI MySQL Subquery Prompt modal Current Page roumen/sitemap JS Database SweetAlert Plugin Protection Add Check softDeletes strtolower Branch Query KCFinder MySql JSON Remote Packages Bootstrap Tokenfield Plugin Chart.js json() Flash Message throttle POST Ajax intervention/image Popup Box maatwebsite Mailchimp API User CSS lowercase league/flysystem-dropbox Fetch Run Project Apache strpos Calculate characters New Features Sort execute query Modular mysqld.sock Billing ServiceProvider Database Seeder yajra/laravel-datatables-oracle String CloudConvert API Sublime Botdetect Captcha milon/barcode PHPExcel csv Google Map Image Gallery apache2 RAND() Old voyager package Event parse Each Permission whitespace timestamps Zip chumper/zipper Redirect Count Manual tree view Controluser enableQueryLog Loop Loading Installation preg_match Animation php_ini_loaded_file Parsleyjs Admin Panel SUBSTRING_INDEX() Laravel 5.4 PHPUnit Bootstrap Confirmation js plugin Linux Column Origin Index Form JS Plugin jquery.lazyload.js Form Jquery CRUD ajaxComplete Issue Last Windows User Agent scrollTop Solve colorpicker Dropbox API Base URL Key Constraint HTML to PDF Bootstrap Plugin Collapse is_null bootstrap-growl Strip Tags Paging uppercase Google API Folder Express Specific CASE_LOWER Laravel 5.5 SMTP Ionic Autocomplete Null Subscribe PostgreSQL Ubuntu Laravel 5.4 - Markdown Mailables Sublime text 3 Ajax Request Mediafıre API Convert Jquery Plugin Download Listener Directory Website Interfaces Sub-Domain Blocked toastr js