Page 1 of 2 12 LastLast
Results 1 to 10 of 12
  1. #1
    Join Date
    Mar 2005
    Posts
    49
    Plugin Contributions
    0

    Default help with my css buttons

    I modified the stylesheet_css_buttons.css file.

    My website is www.palestream.com. The button on the right is the way I want it to look. Notice my search button, on the left, seems bunged up somehow. It has kind of an outline around it, and the two little boxes on the side aren't even with the center space. In Firefox it has become left-aligned instead of centered, although in IE it is still centered.

    Any help appreciated. The code follows.
    Thanks!

    /* css buttons */
    .cssButton, .cssButtonHover {
    width : 20em;
    display: block;
    padding: 0.25em 0.5em 0.25em 0.5em;
    background: #ffffcc;
    text-decoration: none;
    text-align:center;
    border-left: 1em solid #54075b;
    border-right: 1em solid #54075b;
    font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
    font-size: 1.1em;
    font-weight: bold;
    /*border-spacing: 1px;*/
    /*margin-left: auto;
    margin-right: auto;*/
    /*display: block;*/
    /*vertical-align: top;*/
    /*line-height: 130%;*/
    /*cursor: pointer;*/
    }

    .cssButtonHover {
    border-left: 1em solid #060;
    border-right: 1em solid #060;
    color: #004500;
    background: white;
    }
    /* adding the styles below might be needed if the default button width is changed */
    /* .button_continue_shopping, .button_shipping_estimator {width: 150px;} */
    .small_delete, .button_prev, .button_next, .button_search {width: 7em;}
    .button_sold_out_sm, .button_sold_out, .button_update_cart, .button_checkout, .button_login {width: 10em;}
    .button_return_to_product_list, .button_add_selected {width: 22em;}
    .button_in_cart{width: 19em;}
    .button_submit {width: 18em;}
    .button_update_cart {color: red;}
    .button_update_cartHover {color: black;}
    /*.innerbox#headernavcenter .boxtext .button_search {display:inline;}*/
    Tim

  2. #2
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: help with my css buttons

    Playing with this in firefox w/web developer I uncommented both the margin_left and the margin-right and the button moved over to the center.

    The border problem around button is caused by the button picking up outset styling from somwhere. Probably an inline setting somewhere since I can't find it in the stylesheets anywhere.

    I can get the outset border to go away and the borders you have set for the other button to appear to be where they belong. I added a 1px top and bottom to define the button as the background color matches its surrounding. I know i'm gonna get yelled at for this but it works. the first declaration kills the outset border and the rest adds the correct border back in. I put the at the bottom of stylesheet_css_buttons.css

    .button_search {border: none; border-left: 1em solid #54075b; border-right: 1em solid #54075b; border-top: 1px solid #54075b; border-bottom: 1px solid #54075b; }
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  3. #3
    Join Date
    Mar 2005
    Posts
    49
    Plugin Contributions
    0

    Default Re: help with my css buttons

    Thanks very much for the tips Mike. I would never yell at you for helping me out! I will try this out.
    Tim

  4. #4
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: help with my css buttons

    I figure I'll get yelled by some of the css masters around here for doing it this way. When what I really should do is dig and find where the outset styling is being set and remove it there instead of just overriding it with the css.
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  5. #5
    Join Date
    Nov 2003
    Posts
    1,987
    Plugin Contributions
    15

    Default Re: help with my css buttons

    Funny (?), only adding border none before the existing border setting helps too (only tested in FF):
    /* css buttons */
    .cssButton, .cssButtonHover {
    width : 20em;
    display: block;
    padding: 0.25em 0.5em 0.25em 0.5em;
    background: #ffffcc;
    text-decoration: none;
    text-align:center;
    border: none;
    border-left: 1em solid #54075b;
    border-right: 1em solid #54075b;
    font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
    font-size: 1.1em;
    font-weight: bold;
    /*border-spacing: 1px;*/
    /*margin-left: auto;
    margin-right: auto;*/
    /*display: block;*/
    /*vertical-align: top;*/
    /*line-height: 130%;*/
    /*cursor: pointer;*/
    }
    This way it will solve the problem for all input buttons (the problem probably is not just the search button, but all input buttons).

  6. #6
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: help with my css buttons

    ahhhh, yup. that works to. I was spending to much time just worrying about the .button_search class. I didn't think about the problem manifesting itself other places.
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  7. #7
    Join Date
    Nov 2003
    Posts
    1,987
    Plugin Contributions
    15

    Default Re: help with my css buttons

    That is so great about forums like these.

    You found a solution, and I found a simplification/improvement. That way we help each other :-)

  8. #8
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: help with my css buttons

    ok then I'll be sending you all my code for simplification. Yeah, more time for
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  9. #9
    Join Date
    Nov 2003
    Posts
    1,987
    Plugin Contributions
    15

    Default Re: help with my css buttons

    Quote Originally Posted by barco57
    ok then I'll be sending you all my code for simplification.
    That is ok. If you write all code too solve my problems, I will try to improve it a bit

    And thanks a lot for the:

  10. #10

    Default Re: help with my css buttons

    I don't know if it helps or not, but when I had weird issues with the css buttons, I found out that fooling around with line-height solved my problems. I had to play a bit, but finally I managed to get it 98% working.
    Just my 2cents
    Cheers,
    f.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. Problem With CSS Buttons v.2.64
    By top hatt in forum All Other Contributions/Addons
    Replies: 1
    Last Post: 9 Jan 2011, 11:26 PM
  2. Help with using css buttons, "update cart' does not use the css buttons?
    By trinitypres in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 1 Jan 2011, 04:34 PM
  3. Update Cart Button with CSS Buttons
    By seandavidson in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 21 May 2008, 12:39 AM
  4. Using CAPTCHA with CSS buttons in 1.3.8
    By 7thVeil in forum All Other Contributions/Addons
    Replies: 0
    Last Post: 21 Dec 2007, 04:34 AM
  5. how to insert css buttons created with CSS Tab Designer 2?
    By lankeeyankee in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 24 Mar 2007, 08:27 PM

Posting Permissions

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