Category : Javascript


How to disable right click on div using context menu jquery?

Today, i am going to tell you how to disable mouse right click on div. this example thought you can learn how to disable right click on page or image or any html tag. jquery provide contextmenu event that way we can prevent right click on specific html element. In this example i used contextmenu event with on(). So, let's see example code and check demo. <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <head> <title>Jquery - disable right click on div using context menu </title> <script src="http://demo.itsolutionstuff.com/plugin/.....

By Hardik Savani | August 8, 2016 | | 3337 Viewer | Category : Javascript
READ MORE

PHP - jquery ajax crop image before upload using croppie plugin

we mostly need to crop image before upload and as specially when we save image for user profile or etc. In this post i tell you how to crop image and save using jquery ajax. In this example i use croppie plugin that provide to crop image with zoom and etc. croppie.js plugin is very professional that way we can easily use for crop profile image. Bellow example through you can implement easily with php and jquery. It is pretty simple example for upload crop and save image php using croppie.js plugin. You have to create two file and one upload directory for store crop image like as bellow: <s.....

By Hardik Savani | August 6, 2016 | | 80519 Viewer | Category : Javascript
READ MORE

How to get current url path example in Jquery?

Sometimes we need to get current URL in jquery file, we can get current URL or path of our current page in javascript using "window.location". In this post i give you three way to get current url in your js file as there are bellow listed: <strong>1.window.location.href</strong> <strong>2.$(location).attr("href")</strong> <strong>3.window.location</strong> Ok, so you can check bellow example code and run in your system. <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <br/> <head> <title>JQuery - get current URL Example</title> &l.....

By Hardik Savani | July 27, 2016 | | 2242 Viewer | Category : Javascript
READ MORE

Bootstrap form validation example with demo using validator.js plugin

We always need to add validation on form like registration form, contact form, login form etc. we always prefer to give validation error after page refresh but you can give validation without page refresh. If you use bootstrap then you can use easily validator.js plugin. validator.js plugin gives client side validation without page refresh. We can use simply. validator.js plugin we can add validation in our PHP project, or any framework like laravel framework, codeigniter framework, symphony framework etc. In this example i give you how can you give validation for require field, email, minle.....

By Hardik Savani | July 20, 2016 | | 72006 Viewer | Category : Javascript
READ MORE

Jquery tooltip example code with demo using Jquery UI

Jquery UI is a lots of collection of GUI widgets like datepicker, tab, timepicker, colorpicker etc. Jquery UI also provide tooltip GUI widget that way we can set text and display when hover on specific element. Jquery UI tooltip through we can set information about element like if we set delete button but when user will mouseover then display text like "You can remove from here". So in this simple html example through you understand how to set tooltip using jquery ui. <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <head> <br/> <title>Jque.....

By Hardik Savani | July 19, 2016 | | 1882 Viewer | Category : Javascript
READ MORE

Jquery - Show hide password in Password textbox using checkbox.

In this post we can implement how to add hide show password when user input password at register time or login time. We sometimes require to do it because that use can determine password is right or wrong. In this example i use just jquery change event on checkbox, if check then user can see his entered password and change anything, so you can see preview and also check demo with code. <strong>Preview:</strong> <img src="/upload/jquery-show-password.png" style="width:100%;border:1px solid red" /> <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <head&g.....

By Hardik Savani | July 11, 2016 | | 2141 Viewer | Category : Javascript
READ MORE

Jquery - Display a loading gif image before a image loads using Eager ImageLoader plugin

Eager ImageLoader plugs give us lazy loading before image loads, in this example you can load your gif image that you want before main image load. In this example i use eager-image-loader plugin. As you can see bellow preview that before image load. so first you have to give path of gif image "./upload/loading.gif" instead of your gif image path. If you want to get this image then you can get from demo. <strong>Preview:</strong> <img src="/upload/image-upload.png" style="width:100%;border:2px solid red" /> <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en">.....

By Hardik Savani | July 8, 2016 | | 3083 Viewer | Category : Javascript
READ MORE

How to set multiple selected value in Chosen Jquery Plugin?

If you require to set selected value in Chosen Jquery Plugin then you can done using val() with trigger(). Some days ago, i had worked my php project i needed to set selected value wiht chosen and also multiple selected value both. After some try i found how to do with if set single selected value using val(). But i was confuse with dropdown multiple selected value, but at last i found how to give value, we have to just pass array in val(). As bellow i mention both way how could done. <strong>Set Single Value:</strong> <pre class="prettyprint lang-php"> var my_val = 3; <br/> $("#set-corsi")......

By Hardik Savani | July 1, 2016 | | 5995 Viewer | Category : Javascript
READ MORE

Jquery - Timepicker with AM PM Example code with demo using jQuery Timepicker Plugin

If you need to use am pm timepicker then you can choose jQuery Timepicker Plugin for getting timepicker. It's pretty simple to use as you can see bellow example. you can also you can set several options for timepicker, you can read more from here : <a href="http://timepicker.co/" target="_blank">timepicker.co</a>. So you have to just copy bellow code and run in your local system and check..... <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <head> <br/> <title>Jquery - Timepicker Example using jQuery Timepicker Plugin</title> <.....

By Hardik Savani | June 24, 2016 | | 10766 Viewer | Category : Javascript
READ MORE

How to change view mode in bootstrap datepicker like yyyy-mm?

When i was working on my laravel application and i need use datepicker picker but i require only select year and month because i have to filter with onlt selected month and year. I did search lot and also check options of datepicker js but i can't do it that because i was wrong maybe. But at last found minViewMode option of datepicker library and i did that if you also want to make format like mm-yyyy or yyyy-mm then you can set minviewmode this way : <strong>Example:</strong> <pre class="prettyprint lang-html"> <html lang="en"> <head> <title>Bootstrap - datepicker chang.....

By Hardik Savani | June 20, 2016 | | 3935 Viewer | Category : Javascript
READ MORE

    Laravel 5 - Google reCaptcha code and Validation example using anhskohbo/no-captcha package

    Laravel 5 - Google reCaptcha code and Validation example using anhskohbo/no-captcha package

    Open Post

    Jquery - Animated typing effect using typed js example with demo

    Jquery - Animated typing effect using typed js example with demo

    Open Post

    How to create ban/revoke user functionality in Laravel 5 example ?

    How to create ban/revoke user functionality in Laravel 5 example ?

    Open Post

    How to upload image with validation in PHP Codeigniter?

    How to upload image with validation in PHP Codeigniter?

    Open Post

    PHP Laravel 5 - Sub-domain routing file Example

    PHP Laravel 5 - Sub-domain routing file Example

    Open Post

    Laravel 5.3 - Customize pagination templates example from scratch

    Laravel 5.3 - Customize pagination templates example from scratch

    Open Post