Code Highlighting With CSS

Discussion in 'PHP' started by asapcorp, Apr 13, 2007.

Thread Status:
Not open for further replies.
  1. #1
    s it possible to do code highlighting with CSS.
    Something similar to putting the [ vbcode] tags on here.

    At the moment all I have is
    #code {
    	background-color: #c0c0c0;
    	font-family: "Courier New";
    	font-size: 12px;
    }
    Code (markup):
    Are there styles to set the top and left borders of a region to black and the right and bottom borders to grey?

    This would give the slightly raised look to the region that the [ vbcode] tags do.
     
    asapcorp, Apr 13, 2007 IP
  2. Subikar

    Subikar Active Member

    Messages:
    241
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    60
    #2
    Here you can do one thing border-top:black;border-left:black; border-buttom:grey;

    That is your css code will be like this

    #code {
    background-color: #c0c0c0;
    border-top:black;
    border-left:black;
    border-buttom:grey;
    font-family: "Courier New";
    font-size: 12px;
    }
     
    Subikar, Apr 15, 2007 IP
  3. bobby9101

    bobby9101 Peon

    Messages:
    3,292
    Likes Received:
    134
    Best Answers:
    0
    Trophy Points:
    0
    #3
    #code {
    background-color: #c0c0c0;
    font-family: "Courier New";
    font-size: 12px;
    border: 1px inset #000;
    }
     
    bobby9101, Apr 15, 2007 IP
Thread Status:
Not open for further replies.