Solved

Jquery ui checkbox - button styling

Posted on 2016-11-01
3
65 Views
Last Modified: 2016-11-02
Hello experts.
I need help to add/remove a css style (ui-button-checked) to my checkbox button (I need a blue border colour if checked)
This is a second part from this solution Jquery ui checkbox
jsfiddle solution code is here
0
Comment
Question by:Panos
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 57

Accepted Solution

by:
Julian Hansen earned 500 total points
ID: 41869714
You can try this
input.ui-helper-hidden-accessible:checked + button {
  border: 1px solid blue;
}

Open in new window


What this is saying is - when the hidden checkbox (the one behind the visible button) is checked then take the button element that is immediately after it and change its border to blue.
0
 
LVL 2

Author Comment

by:Panos
ID: 41869879
Hi Julian Hansen
I checked this and it is working fine. I didn t though about a stylesheet solution. Thank you very muych.
0
 
LVL 57

Expert Comment

by:Julian Hansen
ID: 41869963
You are most welcome.
0

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction HyperText Transfer Protocol (http://www.ietf.org/rfc/rfc2616.txt) or "HTTP" is the underpinning of internet communication.  As a teacher of web development I have heard many questions, mostly from my younger students who have come to t…
I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question