Part of my written code is not showing when I see a preview of my blog.

  • Unknown's avatar

    I can’t understand why but today when I sat to write my blog, where I post code snippets (I do it using the [code language="some programming language "] ) the moment I switched from the HTML layout to the visual tab some of my code was not showing when I saw the preview. I tried many times to get the full code but always some part went missing. I would be very happy if someone would kindly and willingly help me out.

    The blog I need help with is: (visible only to logged in users)

  • Hi –

    While HTML is permitted, there are restrictions on what code can be added to your WordPress.com site. This is to protect the shared environment of our community.

    Allowed codes are outlined here: https://en.support.wordpress.com/code/

    Can you share the full code that you’re having issues with here?

  • Unknown's avatar

    This is full html file:

    <!DOCTYPE html>
    <html>
    <head>
    <title>Creative Blog</title>
    <link href=”https://fonts.googleapis.com/css?family=Bree+Serif” rel=”stylesheet”>
    <link rel=”stylesheet” type=”text/css” href=”code10.css”>
    </head>
    <body>
    <div id=”heading”>
    <div id=”headingElements”>
    <h1>Creative Blog</h1>
    <h5>Inspiring Ideas</h5>
    </div>
    </div>

    <div id=”options”>
    <div id=”optionsElements”>
    Home
    About
    Contact
    </div>
    </div>

    <div id=”sideBar”>
    <h3>Categories</h3>
    <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
    tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam.</p>
    </div>

    <div id=”content”>
    <h2>First Blog</h2>
    <p>Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod
    tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam,
    quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
    consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse
    cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non
    proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
    </div>
    </body>
    </html>

    Here, the <!DOCTYPE>, <html>, <head>, <title>, and the <body> tags are not showing when i take a preview.

    I also have a CSS file but i dont have a problem with that file.

  • Have you tried to use it through the visual editor tab?

  • The topic ‘Part of my written code is not showing when I see a preview of my blog.’ is closed to new replies.