• Please can someone tell me how I can add classes and ID’s, I have included #box1 and #box in my css but none of the styles are rendering, I guess that I may need to add some php code somewhere, please can someone help me?? thanks https://www.reptonfc.com

Viewing 7 replies - 1 through 7 (of 7 total)
  • You will have to take it upon yourself to learn some basic CSS – nobody here can teach you much in this format. Yes, of course you can add classes or ID’s to your CSS. You might start by doing a web search for CSS to find something basic, like HERE

    Thread Starter texas001

    (@texas001)

    I know how to write css, my problem is I’m not sure what I need to do within wordpress templates to make it work. I have written the css code #box1 and #box2 but my styles aren’t working,the css I have written is correct but for some reason its not being applied, I guess its something to do with the other templates and maybe I need to add some php code somewhere?

    Thread Starter texas001

    (@texas001)

    Please can anyone help me with this? thank you

    Thread Starter texas001

    (@texas001)

    I’m still trying to sort out my problem, please can anyone help? i would be so grateful, thank you

    #box1 {
    width:200px;
    float:left;
    margin:1px 1px 20px 1px;
    padding:1px;
    font-family: Georgia, ‘Times New Roman’, Times, serif;
    min-height:265px;
    color: #FFFFFF;
    text-align:left;
    font-size: 12px;
    background-image: url(../images/button.gif);
    background-repeat: repeat;}

    #box2 {
    width: 200px;
    float:right;
    font-family: Georgia, ‘Times New Roman’, Times, serif;
    margin: 1px 1px 20px 1px;
    padding: 1px;
    color: #FFFFFF;
    font-size: 12px;
    text-align:left;
    }

    Those are the id’s you created. I think you may need to now go to the index.php of your theme, and any other page templates that will be displaying the desired content, and identify the areas where you want them to appear, as well as the content you want to be in them.

    <div id="box1">
    ...php functions calling the content you want to appear in this div...
    </div>
    
    <div id="box2">
    ...php functions calling the content you want to appear in this div...
    </div>

    … am I close?

    Thread Starter texas001

    (@texas001)

    Hi Claytonjames, thank you for trying to help me out with this, so I just need to copy that code that you have given me into index.php? and whereabouts in the coding do i put it? thanks

    so I just need to copy that code that you have given me into index.php? and whereabouts in the coding do i put it? thanks

    Umm… No. Most definitely not. That was a broad based generalization as to how the whole thing works. You need to start by dissecting a theme or two in order to see how they are built. Then probe the relationship between content and presentation. Kubrick (the default theme) may not be your best bet for doing that. My advice is to start trying to find some good online tutorials.

    Good luck to you!

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘How can I add Classes and ID’s?’ is closed to new replies.