Click here to Skip to main content
15,922,166 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I have a sticky note, and I have my delete button this way:


CSS
.jSticky-delete[class]{
    background:transparent url(../images/delete.png) no-repeat top left;
    height:14px;
    width:14px;
    position:absolute;
    cursor:pointer;
    z-index:4;
}
* .jSticky-delete{
    filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='images/delete.png');
    height:14px;
    width:14px;
    position:absolute;
    cursor:pointer;
    z-index:4;
}



The problem is, now I define my edit (confirm) button:

CSS
.jSticky-edit[class]{
    background:transparent url(../images/ok.png)  top right;
    height:14px;
    width:14px;
    position:absolute;
    cursor:pointer;
    z-index:4;
}
* .jSticky-edit{
    filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='images/ok.png');
    height:14px;
    width:14px;
    position:absolute;
    cursor:pointer;
    z-index:4;
}


I add this class's to

CSS
.jStickyNote {
    cursor :move;
    position: absolute;
    left: 0px;
    top: 0px;
    z-index: 2;
    height:90%;
    overlay:hidden;
    width:100%;
}



and for reasons I dont understand this edit button stays over delete button (not on top right).

What am I doing wrong? What can I do to force the ok.png go right? (or elsewhere)
Posted

1 solution

You are telling each element to be positioned in the same place as the others

position:absolute;

Add CSS to the list of things you should be reading about rather than posting questions. Please stop posting and start reading, and not by Googling. Go get a real book. As I have told you before you will learn more from this than stumbling around here.
 
Share this answer
 
v2
Comments
Dalek Dave 27-Dec-10 18:09pm    
Good Call

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900