• You have a blog page as a default in the installation. I was able to import over 10 years of movabletype entries, yaY!

    How do I add an html module just above the blog roll? This would be a fragment of html above the first post, explaining what the page is about. I am using the 2014 theme.

    Please explain like I am five :+>

Viewing 5 replies - 1 through 5 (of 5 total)
  • WordPress runs from index.php in place of index.html, so I suspect your simplest approach would be to add a banner to a Twenty Fourteen Child Theme:
    https://www.google.com/search?q=add+banner+to+twenty+fourteen

    Thread Starter parisology

    (@parisology)

    I have already looked at this search and they are not helpful. I do not want to add an image, I do not want to add an advertisement, I do not want to add a banner to a header. I want an html section just above the first post as an introduction to the posts below. The problem with these unhelpful drive by responses is that no one else will reply to this question now with anything useful as they think the question has already been covered. I am then left with post another new post or giving up.

    I understand what you want to do, and my response is hardly any alleged drive-by now rendering your query a useless waste of time. In fact, there are others here who actually check up on me a bit and help where I try and do not succeed.

    Adding an area at the top of your site, overall, or to each page, respectively, can be done, but I doubt that will ever happen if you insist on its being html.

    Thread Starter parisology

    (@parisology)

    What I really want is a composite page, consisting of modules. One module would be the blog roll component. Above that component would be an html module, editable online, in which I could place any sort of html markup. It is baffling to me that this feature is not jumping out at me. I wrote a module based CMS system over 10 years ago on the asp.net platform, kind of a DNN clone, and am really surprised something like this is not available in wordpress. I guess you have to modify your requirements to what wordpress will allow.

    So if all you ever want is a few sentences at the top-most before list of posts in home(index) page, you could just add it as CSS content. First, install any of the Custom CSS plugin, and then add this CSS into it, change the message to yours.

    Example of Custom CSS plugin found in WP plugin repo.
    https://www.ads-software.com/plugins/simple-custom-css/

    Add this into its option page and change the message to yours

    /* add a few sentences to the top before list of posts in home (index) page for WP's 2014 theme */
    
    body.home.blog .site-content:before {
    	content: "Hello Welcome to this site, enjoy reading or viewing the content, and have a nice day!";
    	width: 100%;
    	box-sizing: border-box;
    	margin-bottom: 48px;
    	padding: 0 48px 48px;
    	border-bottom: 1px solid #888;
    }
    
    @media screen and (max-width: 400px) {
    	body.home.blog .content-area { padding-top: 48px ; }
    	body.home.blog .site-content:before { padding: 0 10px 48px; font-size: small; }
    }

    If you want more than just a few sentences, you need to register a new sidebar (a widget block in WP is called sidebar), and put it in the template via Child Theme, placing the call to the sidebar inside a WP conditional function to make sure that it appear only on the home (index) page. Once you got it working, drag a text/html widget into it and then you can write your own HTML there.

    Child Themes
    https://codex.www.ads-software.com/Child_Themes

    WP sidebar, old article but still current and very useful.
    https://justintadlock.com/archives/2010/11/08/sidebars-in-wordpress

    For tag or category archive page, there is built-in tag/cat description, manageable via WP admin page, under Post, click to edit each particular cat or tag that you want to add the description in. Once the description is entered, it will show up at the top-most of that cat or tag archive listing page. This functionality doesn’t allow HTML, it only allows text and WP will automatically wrap it with paragraph tag. So if you want to put your own HTML other than p tag, then look for a plugin that allows html in tag, category description.

    This one is an example.
    https://www.ads-software.com/plugins/allow-html-in-category-descriptions/

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘How do I add html section above blog?’ is closed to new replies.