• Resolved oceanbluesky

    (@oceanbluesky)


    Using a twentytwelve-child how can a block of text be made to appear constantly above content posts in a page’s main column? thanks

Viewing 11 replies - 1 through 11 (of 11 total)
  • The best method (and widely used) is to create a Child Theme (edits to Parent themes are lost on theme update) and a Custom Page Template (just copy the template used for the posts and edit in your text properly in HTML)

    Thread Starter oceanbluesky

    (@oceanbluesky)

    within the twentytwelve-child folder would I then edit a copy of content-page.php ? or content.php? …or header.php? or…?

    and in whichever .php page, with what html tags would I need to surround a simple ‘hello world’ line of text? <body>? or only <div> and <span>?

    thanks

    Whichever template is being used on that page – isn’t that a template you created for the three columns?

    The <body> tag is only used once in any webpage.

    Something like this would probably work:

    <div id="hellotext">Put your text here.</div>

    Then you can use that id to add any CSS styles you want for that element. You could also add any other HTML tags (possibly <p>) inside the div, depending on the specfics.

    Thread Starter oceanbluesky

    (@oceanbluesky)

    Hi WPyogi, thanks again!

    Thread Starter oceanbluesky

    (@oceanbluesky)

    sorry, this hasn’t quite been resolved…currently the html code is placed within the content.php file (as a twentytwelve-child) but this causes it to be repeated at the top of every post, rather than the top of only the first post at the top of the column holding posts.

    for example, I’d like the front page to look like it does now:

    https://factualfiction.com/lighthouse/

    except…if you scroll down you’ll notice these quotes reappear at the beginning of every post…how can the be made to appear only at the top of the center column (pretty much as they appear now)…does a new .php page need to be loaded in the template above content.php?

    thanks again!

    Try category.php

    Thread Starter oceanbluesky

    (@oceanbluesky)

    nope, not category.php

    would this require a new .php page to be loaded ahead of the content.php in that center column?

    thanks

    What template are you using for the front page? Is it the Front Page template – or didn’t you use a custom one for 3 columns?

    Thread Starter oceanbluesky

    (@oceanbluesky)

    Hi WPyogi, I’ve just been applying the customizations to files in twentytwelve-child as described in this tutorial: https://zeaks.org/2012/twenty-twelve-theme-three-column-layout

    completely unsure what a ‘Front Page’ template is…(how does it differ from the basic starting page for uncustomized twentytwelve?)

    thanks again

    Actually, I think what you want is index.php – under this line –

    <div id="content" role="main">

    (Obviously, this should made to a copy of this file in the child theme.)

    Thread Starter oceanbluesky

    (@oceanbluesky)

    thanks again WPyogi ! index.php did it

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘How to make constantly occurring static text above blog posts in main column?’ is closed to new replies.