Results 1 to 9 of 9
  1. #1

    * Helo with opacity in CSS

    Hello,

    My programmers have added this code:
    echo "
    <style type=\"text/css\">
    td.fontdesign {
    font-family:".$fontface.";
    font-size:".$fontsize.";
    color:".$fontcolor.";
    }

    a.artist {
    font-family:".$fontface.";
    font-size:".$fontsize.";
    }

    a.artist:link {
    color:".$linkcolor.";
    }

    a.artist:hover {
    color:".$hovercolor.";
    }
    .tabledesign {
    border-style:".$borderstyle.";
    border-color:".$bordercolor.";
    border-width:".$borderwidth.";
    background-color:".$blockbg."


    where it says background-color:".$blockbg." I would like to add this(the same effect than on myspace where the tables are semi transparent)

    style="background-color: gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6;border: 1px solid black;"

    My customers will have a panel in their account, when they choose a table size,color then these settings (showing in css) are getting passed here,but how can I add my opacity code to the css .tabledesign? Because there is "$" I have no idea how to add my opacity code after it.

    Thank you so much for your help,

    BamBam

  2. #2
    Join Date
    Oct 2002
    Location
    State of Disbelief
    Posts
    22,951
    Moved to web design, as CSS isn't programming.
    Having problems, or maybe questions about WHT? Head over to the help desk!

  3. #3
    Join Date
    Dec 2007
    Location
    UK
    Posts
    948
    I would reccommend rather than using css transparency create a transparent gif or png background, i.e a small square 100x100px and set it to repeat.

    If you need further help then please <<ask here>>
    Last edited by bear; 10-18-2009 at 11:16 AM.
    Follow me on Twitter: @conrjac

  4. #4

    Lightbulb

    Hi ConnorJackson,

    Thank you for your help, the code I have given is apparently working well for Myspace, about your.npg idea it is google but each of my customers will have at least 1 to 15 different tables with different settings in it, I rather apply this global setting on the already created codes, do you think it is possible to apply this code after the $blockbg? Because this $blockbg is the variable passing the colors for the table but they are only basic colors, if I could put this code next to it then thee colors will then become transparent.

    Any help would be more than appreciated,


    Thank you,


    BamBam

  5. #5
    Join Date
    Dec 2007
    Location
    UK
    Posts
    948
    why not offer a transparency option next to the color, like a tick box, then:
    Sudo Code:
    If Transparency
    =YES : css transparancy css code
    =NO : None
    Follow me on Twitter: @conrjac

  6. #6

    Talking

    lol sorry about the last post, I wrote "about your.npg idea it is google but each ", I meant good and not Google.....I was searching on google at the same time and I am quiet tired tonight......
    I agree with your checkbox but first I would really like(I am new to coding) how to get this opacity code attached to my code, the code I have found is:

    style="background-color: gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6;border: 1px solid black;"


    and my code is:
    .tabledesign {
    border-style:".$borderstyle.";
    border-color:".$bordercolor.";
    border-width:".$borderwidth.";
    background-color:".$blockbg."


    I have tried this(using the same variables but it does not work:
    .tabledesign {
    border-style:".$borderstyle.";
    border-color:".$bordercolor.";
    border-width:".$borderwidth.";
    background-color:".$blockbg gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6;border: 1px solid black;"

    Any other ideas please?

    Thank you,


    BamBam

  7. #7
    is it possible to do this or not?

    Thanks,


    Ben

  8. #8
    Join Date
    Dec 2007
    Location
    UK
    Posts
    948
    border-style:".$borderstyle.";
    border-color:".$bordercolor.";
    border-width:".$borderwidth.";

    background-color:".$blockbg gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6;

    border: 1px solid black;"

    theres the issue,
    should be seperate tags - background, border
    Follow me on Twitter: @conrjac

  9. #9
    Thanks ConnorJackson,

    I have added your code but still there is a problem, I get an error on my page:


    Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/mysite/public_html/site/ecommerce/css.band_setting.php on line 128

    Also


    I have changed this
    background-color:".$blockbg gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6;

    to this:
    background-color:".$blockbg gray;filter:alpha(opacity=60); -moz-opacity:0.6; opacity: 0.6";<-----here

    But I still get the error, but at least with what I added at the end the code below that line on the rest of the css page is showing properly as before,the code below it was grayed out.

    Any other ideas?


    I have tried many combinations but still, I cannot get the error to go away.

    Regards,

    BamBam

Similar Threads

  1. Helo t everyone
    By pikiman in forum New Members
    Replies: 2
    Last Post: 04-08-2009, 04:02 PM
  2. helo
    By webranger in forum New Members
    Replies: 1
    Last Post: 03-28-2009, 08:48 AM
  3. Helo
    By juanbravo in forum New Members
    Replies: 1
    Last Post: 11-29-2008, 06:03 AM
  4. alpha(opacity=100) - bold is ugly in IE
    By PlanetWebHost in forum Programming Discussion
    Replies: 1
    Last Post: 09-11-2006, 01:53 PM
  5. Table Cell Opacity / Transparent ??????????
    By lost2 in forum Web Design and Content
    Replies: 18
    Last Post: 12-13-2005, 04:47 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
  •