Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8239711
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T20:14:18+00:00 2026-06-07T20:14:18+00:00

am having a problem aligning my toggle switch to an image, here is the

  • 0

am having a problem aligning my toggle switch to an image, here is the exact description of what i need. http://jsfiddle.net/9M4gc/, my toggle switch is working accordingly but i just need to make use of CSS3 to align the toggle switch on the image. view the picture below.

This the current looks of my page:
enter image description here

An this how i want it:
enter image description here

Meaning that i just want the toggle switch to be on the image just like the image above. so far here are my codes:

HTML:

<div class="back" id="toggle"><br/>
<img src="http://i1159.photobucket.com/albums/p637/Apulo_Cosmas/btn_push01c2x.png"/>
<label for="enjoy_web"></label>
<div class="slideThree">
<input type="checkbox" value="None" id="slideThree" name="check" />
<label for="slideThree"></label>
</div>
</div>

CSS:

body{
background:#088A08;
margin:auto;           
}


input[id=slideThree] {
visibility: hidden;
}

/* SLIDE THREE */
.slideThree {
width: 120px;
height: 45px;
background: #0101DF;

-webkit-border-radius: 30px;
-moz-border-radius: 30px;
border-radius: 30px;
position: relative;

-webkit-box-shadow: inset 0px 1px 1px rgba(0,0,0,0.5), 0px 1px 0px rgba(255,255,255,0.2);
-moz-box-shadow: inset 0px 1px 1px rgba(0,0,0,0.5), 0px 1px 0px rgba(255,255,255,0.2);
box-shadow: inset 0px 1px 1px rgba(0,0,0,0.5), 0px 1px 0px rgba(255,255,255,0.2);
}

.slideThree:after {
content: 'OFF';
font: 19px/26px Arial, sans-serif;
color: #fff;
position: absolute;
right: 10px;
z-index: 0;
font-weight: bold;
text-shadow: 1px 1px 0px rgba(255,255,255,.15);
}

.slideThree:before {
content: 'ON';
font: 19px/26px Arial, sans-serif;
color: #fff;
position: absolute;
left: 10px;
z-index: 0;
font-weight: bold;
}

.slideThree label {
display: block;
width: 50px;
height: 40px;

-webkit-border-radius: 50px;
-moz-border-radius: 50px;
border-radius: 50px;

-webkit-transition: all .4s ease;
-moz-transition: all .4s ease;
-o-transition: all .4s ease;
-ms-transition: all .4s ease;
transition: all .10s ease;
cursor: pointer;
position: absolute;
top: 3px;
left: 3px;
z-index: 1;

-webkit-box-shadow: 0px 2px 5px 0px rgba(0,0,0,0.3);
-moz-box-shadow: 0px 2px 5px 0px rgba(0,0,0,0.3);
box-shadow: 0px 2px 5px 0px rgba(0,0,0,0.3);
background: #fcfff4;
background: -webkit-linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%);
background: -moz-linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%);
background: -o-linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%);
background: -ms-linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%);
background: linear-gradient(top, #fcfff4 0%, #dfe5d7 40%, #b3bead 100%);
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#fcfff4',       endColorstr='#b3bead',GradientType=0 );
}

.slideThree input[type=checkbox]:checked + label {
left: 68px;
}

A working Demo can be viewed at http://jsfiddle.net/9M4gc/ thanks in advance for the help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T20:14:20+00:00Added an answer on June 7, 2026 at 8:14 pm

    Why not set the image as a background, and position your toggle switch inside the parent div?

    Here’s a working example: http://jsfiddle.net/529Lk/

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm having lots of problem aligning an image on CSS. Here is the thing,
I'm having a problem aligning an image to the top the text in an
I am having a problem with the aligning of an image (float left) and
Having problem with the middle Div not expanding to the width http://acs.graphicsmayhem.com/images/middiv.jpg Ok, how
I am having problem using mvc:resources in spring 3.1 configuration. Initially i was working
I'm having problem with datagrid view. I have attached an image with the code
I am having a slight problem aligning my Horizontal Navigation bar to the center
i having problem in converting this C# code into VB.net. The loadLecturer seem to
I am having problem aligning text vertically at the top of the span. vertical-align:
i having problem with draw image in applet. i want to display all images

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.