• I am trying to insert today’s date as “Today is . . .” on the right side of the header of my website (jerryzarley.com).

    I am using the WikiWP 1.1.1 theme.

    After reading ALL available online materials, including these forums, here is the code I am using:

    The entire body of my header.php file:

    [please use the ‘code’ button to mark any code within your post; and, nextime, please use the pastebin for code longer than 10 lines]

    /*

    <body>

    <div id=”logo”>
    “><img src=”<?php bloginfo(‘template_url’); ?>/images/logo2.png”>
    <!– Change the logo with your own. Use 155x155px sized image, preferably .PNG –>
    </div>

    <div id=”header”>
    <h1>/”><?php bloginfo(‘name’); ?></h1>
    <h4><?php bloginfo(‘description’); ?></h4>
    </div>
    <span class=”xdate”><?php echo date(‘l, F j, Y’); ?></span>

    */

    I then put the following into the style sheet

    /*

    .xdate {
    text-align: right;
    padding: 1px 1px 1px 1px;
    }

    */

    1. It still shows up under the header.
    2. How and where do I put “Today is”?

    Thank you in advance for your assistance.

Viewing 2 replies - 1 through 2 (of 2 total)
  • example:

    re-shuffle this section:

    <div id="header">
    <h1>/"><?php bloginfo('name'); ?></h1>
    <h4><?php bloginfo('description'); ?></h4>
    </div>
    <span class="xdate"><?php echo date('l, F j, Y'); ?></span>

    into:

    <div id="header"><span class="xdate">Today is <?php echo date('l, F j, Y'); ?></span>
    <h1>/"><?php bloginfo('name'); ?></h1>
    <h4><?php bloginfo('description'); ?></h4>
    </div>

    and adjust the css:

    .xdate {
    text-align: right;
    padding: 1px 1px 1px 1px;
    float:right;
    margin-right: 10px;
    margin-top:10px;
    }

    Thread Starter JerryZarley

    (@jerryzarley)

    With a bit of tweaking, that worked beautifully.

    A huge thank you, alchymyth.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Showing Today's Date in Header’ is closed to new replies.