This might be a very silly question but here goes nothing: is there any asp net control, ajax control toolkit or html/css tag to create something like a radiobuttonlist, horizontally aligned with all radiobuttons connected by a line or dotted line? I would have uploaded a picture but I lost all my reputation on a previous bounty and it seems I have to have at least 10 rep to upload an image.
Basically, I have a web form in which the user inputs some data and then that data has 4 steps: draft, completed, sent to approval, approved. I would like to have these 4 steps at the top of the page and based on the current status, check the appropriate status on that ribbon.
UPDATE:
A picture's worth a 1000 words so therefore this is what I need:
And also this control should be "controlled" in the code-behind.
You can easily make this with html/css.
<div class="bubble active"></div>
<div class="connector"></div>
<div class="bubble"></div>
<div class="connector"></div>
<div class="bubble"></div>
<div class="connector"></div>
<div class="bubble"></div>
And some basic css
.bubble
{
border-radius:50%;
height:40px;
width:40px;
background: #aaa;
display:inline-block;
margin:0 -3px;
}
.bubble.active
{
background:red;
}
.connector
{
display:inline-block;
height:3px;
width:10%;
background: #aaa;
vertical-align:middle;
margin-top:-30px;
}
Check out this fiddle. Just add/remove the active class to the bubbles at will. And you can also add a done class or something.
Related
So basically what I want to do is this:
Lets take this svg as an example:
https://www.freepik.com/free-vector/blank-screen-laptop-gadget-icon-white-background_9306518.htm
What I want to do in my next.js project is following:
Put my own code inside the "monitor" area of this notebook.
Also make this responsible
So I need a good way to display the notebook and then I create my own div thats the same height and width as the notebook screen and I can put anything else I want into it (paragraphs, h1 etc). So it seems that my code / page appears directly onto the notebook screen.
What is the best way to achieve this?
I heard about clip-path but I wasn't able to wrap my head around this.
Or no SVG at all
Make the laptop PNG screen transparent, and position it over your content
<style>
#LAPTOP{
position:relative;
overflow:hidden;
width:300px;
height:200px;
}
#SCREEN,#BORDER{
position:absolute;
}
#SCREEN{
margin:1em;
margin-left:3em;
}
#MAP{
zoom:.5;
}
#BORDER{
width:100%;
height:100%;
z-index:999;
}
</style>
<div id="LAPTOP">
<div id="SCREEN">
<b>Hello World!</b>
<img id="MAP" src="//lh3.googleusercontent.com/proxy/7OrKxhEgjUlMNO280hA_iums8CxNpExIwZARBhDjhboAEgof-YYF7s4I9di1HREv3QKyzadoXZ74PlelwJ7ejpLBl5lXRto">
</div>
<img id="BORDER" src="https://i.ibb.co/yd47GPy/laptop-screen.png">
</div>
First of all I'm using Django, and I've my CSS inside of my HTML file.
Here's what my situation looks like as of right now: I've finished setting a sidebar for the dashboard, aka the members area, and I want to offer users the option to show or hide the latter, just like most popular website nowadays do, including Youtube.
I've the following code in the body:
<div class="toggle-btn">
<span></span>
<span></span>
<span></span>
</div>
And the following one in the head
<style type="text/css">
.toggle-btn {
position:absolute;
left:230px;
top:20px;
}
.toggle-btn span {
display:block;
width:30px;
height:5px;
background:#151719;
margin: 5px 0px;
}
</style>
It is indeed supposed to look just like this , but nothing shows up next to the sidebar. If someone could point out what I might have done wrong, or missed doing, I would super appreciate it.
So, I had a difficult time trying to figure out why a couple of my links were not clickable. I finally figured out that they just needed a 'higher' z-index. I don't really understand why they needed that in order to work though. I'm figuring out (through google-research) that some elements can be 'covered' by other elements. I don't understand how that happened in my code, in particular, and kind of still confused about that whole concept of some elements 'covering' others. Can anyone explain? Here's the relevant HTML and CSS, respectively: (I had trouble with the elements within )
HTML:
<section id="nav_images">
<img id="skull" class="reflectBelow" src="ScumSkull.jpg" alt="Click for scoop" height="94" width="94"/>
<img id="staff" class="reflectBelow" src="ScumStaff.jpg" alt="Click for staff" height="94" width="94">
<img id="bulbs" class="reflectBelow" src="ScumBulbs.jpg" alt="Click for sermons" height="94" width="94">
</section>
<aside id="don8">
<p id="don_P">Make a Donation to Scum</p>
<img id="donate" src="donate.gif" alt="Donate button" height="47" width="147">
</aside>
<aside id="slogans">
<h3>Top Five Rejected Scum of the Earth Slogans</h3>
<p id="slogan_5" class="slogan">5. Emerging from the emergent church</p>
<p class="slogan">4. Our congregation can kick your congregation's ass</p>
<p class="slogan">3. Same old evangelical crap, different package</p>
<p class="slogan">2. Come to see the crazy bathrooms, stay for a sermon</p>
<p class="slogan">1. And you thought mega-churches sucked</p>
</aside>
CSS:
body
{
background-color:#000000;
margin:0;
padding:0;
font-size:100%;
width:100%;
}
main
{
display:block;
max-width:700px;
margin:40px auto 300px auto;
height:650px;
}
img
{
padding:0;
margin:0;
border:none;
float:left; /* Gets rid of space between images */
}
#don8
{
clear:left;
float:right;
position:relative;
top:50px;
width:250px;
height:140px;
border-left:13px solid red;
}
#don_P
{
width: 60px;
position:relative;
top:-10px;
left:60px;
text-align:center;
z-index:2;
}
#don_P a:link, a:hover, a:focus
{
text-decoration:none;
color:white;
}
#donate
{
position:relative;
top:-10px;
left:20px;
z-index:2;
}
#slogans
{
clear:left;
position:relative;
top:50px;
left:35px;
/* border-right: 5px solid red; */
}
.slogan
{
margin-top:0;
margin-bottom:0;
line-height:160%;
}
#slogan_5
{
margin-top:10px;
}
Unless I'm missing some CSS, your links are not covered. Their color turn white on :hover.
#don_P a:link, a:hover, a:focus { color: white; }
The following link shows a nice picture of what it looks like when the 'layer' is visible and overlapping another layer. This 'overlapping' will happen primarily when you force how the browser should render an item by specifying the coordinates where the item should be placed on the page.
http://www.w3.org/wiki/CSS/Properties/z-index
A convenient way to observe how the browser has layered your HTML, you can use Google Chrome developer tools. Open the page in Google Chrome browser, then Right click on the element in question and select "Inspect Element". This will give you a view of the boundaries of that element.
Pretty much all modern browsers have this 'element inspector' feature somewhere. Firefox also has this feature in their dev tools, but also has a fancy tool that can also do this, but in 3D:
https://developer.mozilla.org/en-US/docs/Tools/3D_View
I looked over your code and I see the overlap.
Your problem is that this:
<aside id="slogans">
<h3>Top Five Rejected Scum of the Earth Slogans</h3>
<p id="slogan_5" class="slogan">5. Emerging from the emergent church</p>
<p class="slogan">4. Our congregation can kick your congregation's ass</p>
<p class="slogan">3. Same old evangelical crap, different package</p>
<p class="slogan">2. Come to see the crazy bathrooms, stay for a sermon</p>
<p class="slogan">1. And you thought mega-churches sucked</p>
</aside>
is appearing on top of
<aside id="don8">
<p id="don_P">Make a Donation to Scum</p>
<img id="donate" src="donate.gif" alt="Donate button" height="47" width="147">
</aside>
Here is an analogy. Imagine if you have two sheets of paper stacked on top of each other. When you bring your pen down on them, it only touches the top one.
This is the same for your mouse pointer. When you click on the page, you click on the top element. In your case, the top element isn't the link so you can't click on it.
There are two solutions to this problem.
Limit the width the the overlapping object so it no longer overlaps.
Give your elements z-indexes and position the link on top.
If you are unclear how z-indexes work here is a good link:
http://www.smashingmagazine.com/2009/09/15/the-z-index-css-property-a-comprehensive-look/
To put it simply, elements with a higher z-index are positioned above elements with lower one. If there is no z-index, the browser just decides.
I'm trying to word this correctly but as always: I'm a novice so forgive mistakes/confusion.
I have created an iframe that embeds a client's main site within their tumblr, meaning you don' have to leave tumblr to access the site. I did this because the old designer had installed a "latest item in the shop" widget which no longer worked & I wanted similar but the information needed didn't exist anymore.
What I would like is a pop-up or hover over box that says: return to blog or carry on to nameofsite.com. Even the links above the iframe would be adequate for now but I can't think how to do it without messing with the appearance of the embedded site.
http://2000adonline.tumblr.com/website
As usual, I think I have developed a wildly complicated issue when a simple redirect would have sufficed! Ah well! Thanks for your time.
A pop-up can be made for the i-frame, but it can only be for the whole i-frame, not elements inside of it. To make a pop-up, wrap the i-frame and pop-up HTML in a <div>:
<div id="iframe">
<iframe src="http://www.w3.org"></iframe>
<div class="over">Return to blog or carry on to nameofsite.com</div>
</div>
Then you need to style the iframe and pop-up:
iframe{
width:500px;
height:500px;
}
#iframe:hover .over{
opacity:1;
}
.over{
opacity:0;
position:absolute;
top:0px;
left:0px;
background:red;
width:100%;
height:40px;
-o-transition:.3s;
-ms-transition:.3s;
-moz-transition:.3s ;
-webkit-transition:.3s;
transition:.3s ;
}
#iframe{
position:relative;
width:500px;
}
When the div #iframe is hovered over, the pop-up fades in at the top.
See this working JSFiddle Example
I'm currently updating a pretty old website (last update was around 2001), and have agreed to use HTML5 and CSS3.
For the general design, I'm working on a very clean white and gray tones style, with many paddings and margins. My problem resides in the home page: I'd like to have a 3-column centered layout. But where to start? I've tried some floating, but in vain.
Am I doing this right ?
HTML:
<div class="colwrapper">
<div class="ltcol"></div>
<div class="ctcol"></div>
<div class="rtcol"></div>
</div>
CSS:
.colwrapper { width:1020px; }
.ltcol, .ctcol, .rtcol { width:300px; margin:0 10px; padding:10px; }
.ltcol { float:left; }
.ctcol { margin-left:340px; }
.rtcol { float:right; }
your css should be like this:
.ltcol, .ctcol { float:left; }
.rtcol { float:right; }
The purpose of the CSS float property is, generally speaking, to push a block-level element to the left or right, taking it out of the flow in relation to other block elements. This allows naturally-flowing content to wrap around the floated element. This concept is similar to what you see every day in print literature, where photos and other graphic elements are aligned to one side while other content (usually text) flows naturally around the left- or right-aligned element.
For More details you must have to read this intresting article.
See This Demo: http://jsfiddle.net/akhurshid/YRWLV/
Your HTML is very clean - this is a great step forward.
You need to add a float: left to all the columns. To ensure the float is cancelled after your columns, it is best to add a clear div after the floated columns.
HTML:
<div class="colwrapper">
<div class="ltcol">Column 1</div>
<div class="ctcol">Column 2</div>
<div class="rtcol">Column 3</div>
<div class="clear"></div>
</div>
CSS:
.colwrapper { width:1020px; }
.ltcol, .ctcol, .rtcol { width:300px; margin:0 10px; padding:10px; background-color: #efefef }
.ltcol { float:left; }
.ctcol { float:left; }
.rtcol { float:left; }
.clear { clear: left; }
So you add css3 tag for this questio so I suggest you to make this with css3 column layout:
More info
for example
HTML
<div class="colwrapper">
<div>text</div>
</div>
CSS
.colwrapper div
{
-moz-column-count:3; /* Firefox */
-webkit-column-count:3; /* Safari and Chrome */
column-count:3;
}
It does not work on IE.
Use one of these tried and tested implementations instead of rolling out your own. In addition to the fact that you'll be getting tested and working code, you'll add responsiveness to your site with almost zero effort.
http://cssgrid.net/
http://960.gs/
http://framelessgrid.com/
http://goldengridsystem.com/
and lots more if you google..
could also use Flexbox property for this now as well so you don't need to worry about floats or clearfix's.
main{
/* .colwrapper{ */
display: flex;
flex-flow: row;
justify-content: center;
}
main > section{
/* .ltcol,.ctcol,.rtcol{ */
display:flex;
flex-flow:column;
align-items:center;
padding:10px; padding:.625rem;
}
main > section:nth-child(2){
/* .ctcol{ */
margin:0 20px; margin:0 1.25rem;
}
http://caniuse.com/flexbox shows the support for it isn't quite as far along as you would probably like, however, there are ways to improve support by mixing old versions of the syntax with the new http://css-tricks.com/using-flexbox/ has a great write up on it from Chris Coyier if you want to play with this for a next project (this post is fairly old). You can also get more details at http://html5please.com/#flexbox
Also, if you're using HTML5 I'd probably go with sections over divs for a more semantic structure, so a comparison would look something like this:
<main>
<section></section><!-- or <nav></nav> -->
<section></section><!-- or <article></article> -->
<section></section><!-- or <aside></aside> -->
</main>
instead of...
<div class="colwrapper">
<div class="ltcol"></div>
<div class="ctcol"></div>
<div class="rtcol"></div>
</div>
Just try putting the rtcol div beofre le ltcol div.
<div class="colwrapper">
<div class="rtcol">X</div>
<div class="ltcol">X</div>
<div class="ctcol">X</div>
</div>
http://jsfiddle.net/EDjpy/