1. Go to this page and download the library: Download pratiksh/nepalidate library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
pratiksh / nepalidate example snippets
use Pratiksh\Nepalidate\Facades\NepaliDate;
NepaliDate::create(\Carbon\Carbon::now())->toBS(); // 2078-4-21
NepaliDate::create(\Carbon\Carbon::now())->toFormattedBSDate(); // 21 Shrawan 2078, Thurday
NepaliDate::create(\Carbon\Carbon::now())->toFormattedNepaliDate(); // २१ साउन २०७८, बिहिवार
use Pratiksh\Nepalidate\Facades\NepaliDate;
toBS(\Carbon\Carbon::now()); // 2078-4-21
toFormattedBSDate(\Carbon\Carbon::now()); // 21 Shrawan 2078, Thurday
toFormattedNepaliDate(\Carbon\Carbon::now()); // २१ साउन २०७८, बिहिवार
// OUTPUT
// if mode = 1 then output 2078-4-21
// if mode = 2 then output 21 Shrawan 2078, Thurday
// if mode = 3 then output २१ साउन २०७८, बिहिवार
nepalidate(\Carbon\Carbon::now());
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.