How to get the value of a checkbox flipswitch in JQuery Mobile 1 4 5

0 votes

I'm using following markup to create a checkbox-based Flipswitch in jQuery Mobile 1.4.5:

<label for="flip-1">Checkbox Flip switch:</label>
<input data-role="flipswitch" name="flip-1" id="flip-1" type="checkbox">

Apparently, the same method to get the value for a select-based Flipswitch:

$("#flip-1").val()

is not working with the checkbox-based version, and i'm getting always the value of "on".

What i'm doing wrong here? Is there a way to get the value as for the select-based version?

Fiddle: http://jsfiddle.net/2ckHr/296/

Thanks in advance

jquery-mobilejquery-mobile-flipswitch

Aug 22, 2022 in Web Development by gaurav
• 23,260 points
308 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Web Development

0 votes
1 answer

How to get value of HTML Checkbox from onclick/onchange events?

Hello @kartik, Use the click event, which won't fire until ...READ MORE

answered Oct 7, 2020 in Web Development by Niroj
• 82,880 points
6,977 views
0 votes
0 answers

How to add a link in Jquery PrettyPhoto to download the image

I am using Jquery PrettyPhoto to have ...READ MORE

Jun 29, 2022 in Web Development by gaurav
• 23,260 points
648 views
0 votes
0 answers

how to get values of columns for a selected row through jQuery

here i am trying to fetch values ...READ MORE

Jul 1, 2022 in Web Development by gaurav
• 23,260 points
4,981 views
0 votes
0 answers

how can i get the url of the content( home.html) in adress bar by jquery load() function?

I am using jquery load() function to ...READ MORE

Jul 28, 2022 in Web Development by gaurav
• 23,260 points
398 views
0 votes
0 answers

How to stretch a GIF to fill the whole div using jQuery Mobile?

I'm using jQuery Mobile to create a ...READ MORE

Aug 22, 2022 in Web Development by gaurav
• 23,260 points
605 views
+1 vote
1 answer

How to access the Angularjs scope of a particular html element from our console?

Hello, You should follow the below steps:-- 1.Compile and ...READ MORE

answered Jan 21, 2020 in Web Development by Niroj
• 82,880 points

edited Jan 21, 2020 by Niroj 2,483 views
0 votes
1 answer

Get checkbox value in jQuery

To get the value of the Value ...READ MORE

answered Jun 23, 2022 in Web Development by rajatha
• 7,640 points
439 views
0 votes
1 answer

Get checkbox value in jQuery

if you have set a class or id for it, you ...READ MORE

answered Jun 23, 2022 in Web Development by rajatha
• 7,640 points
486 views
0 votes
0 answers

How to get mobile number from facebook login using jquery?

I am trying to work facebook login ...READ MORE

Jul 19, 2022 in Web Development by gaurav
• 23,260 points
656 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP