Popular Posts
- Bootstrap Progress Bar example using jQuery and PHP
- How to get device Unique ID | device ID in Phonegap
- Jquery popup using colorbox iframe load external page
- How to Git Init Repository
- Attractive login form with css and bootstrap
- Shaking Up The Web With CSS3 (How To Make Links Shake)
- CodeIgniter Insert Data into Database
- Extracting URL Data with Jquery and Ajax
- Voting system Using jQuery Ajax and Php Codeigniter Framework
- How to display Indian Rupee symbol in websites
Contact Form
bootstrap,
css,
html,
tutorial
Bootstrap-3 tutorial 1 – Introduction to Bootstrap
11:20 PM Admin 0 CommentsBootstrap is the most popular front end framework in the world right now, we’ll learn all about it in this video series. In this video I give you a quick demo of what is possible with Bootstrap, talk about some topics that I will be covering in this series.
What is Bootstrap?
Bootstrap is a CSS “front end framework”, which was created to make building responsive websites a much easier task. The idea behind this that you simply link some Bootstrap files to your website and simply add the correct classes to each element and your website is instantly responsive.
Of course, even though Bootstrap has an optional theme, you can always add your own custom CSS for a more custom look and feel.
What will this Bootstrap tutorial series cover?
In this series we will be covering the following topics:
- Installing Bootstrap onto your website.
- The Boostrap 12 column grid.
- Pushing an pulling columns
- Basic typography
- Responsive tables
- Responsive images
- Basic Bootstrap forms
- Various Bootstrap CSS components like:
- Jumbotrons and Wells
- Dropdowns
- Navigation and Navbars
- Various Bootstrap JavaScript components like:
- Collapsable boxes
- Modals
- A carousel
That’s all for now. See you in the next Bootstrap tutorial.
Github Link is Here
PhoneGap Toast plugin
1. Description
This plugin allows you to show a native Toast (a little text popup) on iOS, Android and WP8. It's great for showing a non intrusive native notification which is guaranteed always in the viewport of the browser.
- You can choose where to show the Toast: at the top, center or bottom of the screen.
- You can choose two durations: short (approx. 2 seconds), or long (approx. 5 seconds), after which the Toast automatically disappears.
- Compatible with Cordova Plugman.
- Officially supported by PhoneGap Build.
- Minimum iOS version is 6.
Example usages:
- "There were validation errors"
- "Account created successfully"
- "The record was deleted"
- "Login successful"
- "The battery is almost dead"
- "You are now logged out"
- "Connection failure, please try again later"
2. Screenshots
iOS
Android
Windows Phone 8
3. Installation
Automatically (CLI / Plugman)
Toast is compatible with Cordova Plugman, compatible with PhoneGap 3.0 CLI, here's how it works with the CLI (backup your project first!):
$ phonegap local plugin add https://github.com/EddyVerbruggen/Toast-PhoneGap-Plugin.git
or
$ cordova plugin add https://github.com/EddyVerbruggen/Toast-PhoneGap-Plugin.git
$ cordova prepare
Toast.js is brought in automatically. There is no need to change or add anything in your html.
Manually
1. Add the following xml to your
config.xml in the root directory of your www folder:<!-- for iOS -->
<feature name="Toast">
<param name="ios-package" value="Toast" />
</feature>
<!-- for Android -->
<feature name="Toast">
<param name="android-package" value="nl.xservices.plugins.Toast" />
</feature>
<!-- for WP8 -->
<feature name="Toast">
<param name="wp-package" value="Toast"/>
</feature>
For iOS, you'll need to add the
QuartzCore.framework to your project (it's for automatically removing the Toast after a few seconds). Click your project, Build Phases, Link Binary With Libraries, search for and add QuartzCore.framework.
2. Grab a copy of Toast.js, add it to your project and reference it in
index.html:<script type="text/javascript" src="js/Toast.js"></script>
3. Download the source files and copy them to your project.
iOS: Copy the two
.h and two .m files to platforms/ios/<ProjectName>/Plugins
Android: Copy
Toast.java to platforms/android/src/nl/xservices/plugins (create the folders)
WP8: Copy
Toast.cs to platforms/wp8/Plugins/nl.x-services.plugins.toast (create the folders)PhoneGap Build
Toast works with PhoneGap build too, but only with PhoneGap 3.0 and up.
Just add the following xml to your
config.xml to always use the latest version of this plugin:<gap:plugin name="nl.x-services.plugins.toast" />
or to use this exact version:
<gap:plugin name="nl.x-services.plugins.toast" version="1.0" />
Toast.js is brought in automatically. There is no need to change or add anything in your html.
4. Usage
You have two choices to make when showing a Toast: where to show it and for how long.
- show(message, duration, position)
- duration: 'short', 'long'
- position: 'top', 'center', 'bottom'
You can also use any of these convenience methods:
- showShortTop(message)
- showShortCenter(message)
- showShortBottom(message)
- showLongTop(message)
- showLongCenter(message)
- showLongBottom(message)
You can copy-paste these lines of code for a quick test:
<button onclick="window.plugins.toast.showShortTop('Hello there!', function(a){console.log('toast success: ' + a)}, function(b){alert('toast error: ' + b)})">Toast showShortTop</button>
<button onclick="window.plugins.toast.showLongBottom('Hello there!', function(a){console.log('toast success: ' + a)}, function(b){alert('toast error: ' + b)})">Toast showLongBottom</button>
<button onclick="window.plugins.toast.show('Hello there!', 'long', 'center', function(a){console.log('toast success: ' + a)}, function(b){alert('toast error: ' + b)})">Toast show long center</button>
This tutorial is based on jquery ,you can type text in more than one text box at a time without copy and pasting the content.
$('#one').keyup(function(){
$('#two').text( $(this).val());
$('#three').text( $(this).val());
});
what this above jquery code will do is , it will be embedded with the html code and there are 3 ID's for 3 text area's #one , #two and #three . the function keyup() will trigger on key up of the ID #one (i.e) the first text area , the same text will be replicated in other two text area's using
$('#two').text( $(this).val());
See the Pen ogovKM by Arun Yokesh (@yokesh) on CodePen.
if you are using the input box means you have to use the following function called val()
$('#input_box_id').val( $(this).val());
$(this) always points to the parent function in which the $(this) is used.
Javascript Code
Contains javascript code. $("#zoom").change(funtion(){}- zoom is the id name of the select box. Using $("#zoom").val(); calling select box value. Applying style at $("#main").css
$(document).ready(function(){
$("#zoom").change(function()
{
var size = $(this).val();
$("#main").css('font-size', size+'px');
return false;
});
});
This is a Simple JQuery Tutorial using the .css() and .change()
The above is the Html Content and it has a select box #zoom with some values and the div with id #main along with the content "Website Content". In the select box each of the option having some different set of values in that while changing the select box the jquery script will trigger at the time the value of the select option will get and then using the div #main id we are changing the div font-zise using the .css() function.
See the Pen pvWyQE by Arun Yokesh (@yokesh) on CodePen.
<select id="zoom"> <option value="25">25 </option> <option value="50">50 </option> <option value="75">75 </option> <option value="100">100 </option> <option value="150">150 </option> <option value="200">200 </option> </select> <div id="main"> Website Content </div>
The above is the Html Content and it has a select box #zoom with some values and the div with id #main along with the content "Website Content". In the select box each of the option having some different set of values in that while changing the select box the jquery script will trigger at the time the value of the select option will get and then using the div #main id we are changing the div font-zise using the .css() function.
See the Pen pvWyQE by Arun Yokesh (@yokesh) on CodePen.
html,
jquey
jQuery disable button - Disabling and enabling buttons with jQuery
1:51 AM Unknown 0 CommentsjQuery disable button -
Disabling and enabling buttons with jQuery
Here is the situation i derived , If the text is present in the textbox means the button will be the enbale state else the button will got to disable state
CODE :
<!DOCTYPE html>
<head>
<title>jQuery enable/disable button</title>
<script type='text/javascript' src='http://code.jquery.com/jquery.min.js'></script>
<script type='text/javascript'>
$(function(){
$('#searchInput').keyup(function(){
if ($(this).val() == '') { //Check to see if there is any text entered
//If there is no text within the input ten disable the button
$('.enableOnInput').prop('disabled', true);
} else {
//If there is text in the input, then enable the button
$('.enableOnInput').prop('disabled', false);
}
});
});
</script>
<style type='text/css'>
body {
font-family: 'Finger Paint', cursive;
background-image: url('bg.jpg');
}
#frame {
width: 700px;
margin: auto;
margin-top: 125px;
border: solid 1px #CCC;
/* SOME CSS3 DIV SHADOW */
-webkit-box-shadow: 0px 0px 10px #CCC;
-moz-box-shadow: 0px 0px 10px #CCC;
box-shadow: 0px 0px 10px #CCC;
/* CSS3 ROUNDED CORNERS */
-moz-border-radius: 5px;
-webkit-border-radius: 5px;
-khtml-border-radius: 5px;
border-radius: 5px;
background-color: #FFF;
}
#searchInput {
height: 30px;
line-height: 30px;
padding: 3px;
width: 300px;
}
#submitBtn {
height: 40px;
line-height: 40px;
width: 120px;
text-align: center;
font-size: 16px;
}
#frame h1 {
text-align: center;
}
#frame form {
text-align: center;
margin-bottom: 30px;
}
</style>
</head>
<body>
<div id='frame'>
<div class='search'>
<h1>jQuery Enable and Disable button</h1>
<form method='post'>
<input type='text' name='searchQuery' id='searchInput' /> <input type='submit' name='submit' id='submitBtn' class='enableOnInput' disabled='disabled' />
</form>
</div>
</div>
</body>
</html>
html,
Jquery
JQUERY | HOW TO COUNT NUMBER OF CHARACTERS IN TEXTAREA (YOUTUBE, TWITTER)
1:16 AM Unknown 0 CommentsJQUERY | HOW TO COUNT NUMBER OF CHARACTERS IN TEXTAREA (YOUTUBE, TWITTER)
Step 1 (count number of characters in textarea)
Our first step is to add the following code in our html page
<label for="description">Description:</label><textarea name="description" id="description" cols="60" rows="5" maxlength="255" placeholder="Describe aboutsomething..."></textarea><div id="characterLeft"></div> |
Here we add
maxlength="255"attribute in the textarea tag, which means thistextarea takes text that contain 255 characters. More than 255 character will be ignored. After that we add a div element withid="characterLeft" which will show the number to exceed the limit of the textarea that we define in maxlength attribute.Step 2
Our second step is to add the following jQuery code in our script file.
$('#characterLeft').text('255 characters left');$('#description').keyup(function () { var max = 255; var len = $(this).val().length; if (len >= max) { $('#characterLeft').text(' you have reached the limit'); } else { var ch = max - len; $('#characterLeft').text(ch + ' characters left'); } |









