Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    Regular Coder
    Join Date
    Nov 2010
    Posts
    432
    Thanks
    56
    Thanked 1 Time in 1 Post

    Custom Checkboxes not working

    Hello,

    Where I found them: http://ryanfait.com/resources/custom...radio-buttons/
    My attempt: https://tornhq.com/Events/HallowTown/checkbox.html

    I don't know what I have done differently, however I do not have the same result...

    Best Regards,
    Tim

  • #2
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    You haven't installed the image checkbox.png.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • Users who have thanked AndrewGSW for this post:

    MrTIMarshall (01-04-2013)

  • #3
    Regular Coder
    Join Date
    Nov 2010
    Posts
    432
    Thanks
    56
    Thanked 1 Time in 1 Post
    Thank you, so obvious I feel stupid!

  • #4
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    27,206
    Thanks
    80
    Thanked 4,566 Times in 4,530 Posts
    What are the spans in there for???

    Code:
    <body>
    <p>
    <span class="checkbox" style="background-position: 0px -50px;"></span>
    <input type="checkbox" name="1" id="1" checked="checked" class="styled">
    <label for="1">Check 1</label>
    </p>
    <p>
    <span class="checkbox" style="background-position: 0px -50px;"></span>
    <input type="checkbox" name="2" id="2" checked="checked" class="styled">
    <label for="2">Check 2</label>
    </p>
    </body>
    Those <span>s do *NOT* belong there.

    PLEASE don't use names or ids that start with numbers (digits)!!
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.

  • #5
    Senior Coder
    Join Date
    Apr 2011
    Location
    London, England
    Posts
    2,120
    Thanks
    15
    Thanked 354 Times in 353 Posts
    I believe the spans are created by the feature.. with their backgrounds set to certain images.
    "I'm here to save your life. But if I'm going to do that, I'll need total uninanonynymity." Me Myself & Irene.
    Validate your HTML and CSS

  • #6
    Supreme Master coder! Old Pedant's Avatar
    Join Date
    Feb 2009
    Posts
    27,206
    Thanks
    80
    Thanked 4,566 Times in 4,530 Posts
    Well, in Chrome, he ends up with 4 checkboxes, not two. Where two of them are the <span>s and don't function as checkboxes.

    So maybe there's a bug in that library.
    An optimist sees the glass as half full.
    A pessimist sees the glass as half empty.
    A realist drinks it no matter how much there is.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •