• Martin1982

    (@martin1982)


    I don’t know how but H1 tag is gone. H2,H3 are ok but H1 is missing. Anyone knows how to add it manually and where is the best place in code to write it?

    My site is located here:
    fotografas

Viewing 14 replies - 1 through 14 (of 14 total)
  • i_banks

    (@i_banks)

    <h1> tags are used for titles…I don’t see the use of titles on your page…looks like you have only pics with one main title which is graphically designed.

    If you do need the <h1> tag, you include it in your ‘loop.php’ file

    <h1 class="entry-title" style="height:60px; width:250px; text-align:center; border-bottom:1px solid #b5b5b5;"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'twentyten' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>

    which outputs the title for each image post.

    Thread Starter Martin1982

    (@martin1982)

    Thanks for quick reply. I can’t seem to find loop.php where is located?

    esmi

    (@esmi)

    In your theme folder. If you do not have a loop.php file, you will need to edit the relevant template file(s) individually.

    Thread Starter Martin1982

    (@martin1982)

    There is no such file. I see only:

    404 Template
    (404.php)
    Comments
    (comments.php)
    Footer
    (footer.php)
    Full Width Page Template
    (page_wide.php)
    Gallery Page Template
    (page_gallery.php)
    Header
    (header.php)
    Main Index Template
    (index.php)
    Page Template
    (page.php)
    Search Results
    (search.php)
    Single Post
    (single.php)
    Theme Functions
    (functions.php)
    remove-title-attributes.php

    And im using theme from: https://blissfulblog.com

    esmi

    (@esmi)

    Then you need to edit the individual theme template files. Or try re-uploading a fresh copy of the theme.

    Thread Starter Martin1982

    (@martin1982)

    I opened index.php and the first 14 line looks like this:

    <?php get_header(); ?>
    
    <div id="content">
        <div class="postarea">
    
            <?php if(have_posts()) : while(have_posts()) : the_post(); ?>
    		<?php global $more; $more = 0; ?>
    
            <?php if ( in_category('gallery') && !is_single() ) continue; ?>
    
            <div <?php post_class(); ?>>
    
            <div class="posttitle">
    
                <div class="postdate">
                	<div class="day"><?php the_time('d') ?></div>
                    <div class="month"><?php the_time('M') ?></div>
                </div>
    
                <h5><?php the_category(' , '); ?></h5>
                <h2><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h2>
    
            </div>

    Maybe somewhere here?

    Thread Starter Martin1982

    (@martin1982)

    Ok so i went through original theme php files and i found h1 heading only in 404.php but this makes no sense at all. I need it in the front page.

    Any clues?

    esmi

    (@esmi)

    Then you need to edit index.php and add it.

    Thread Starter Martin1982

    (@martin1982)

    Where should i put exactly?

    esmi

    (@esmi)

    Try changing:

    <div <?php post_class(); ?>>
    <div class="posttitle">

    to:

    <div <?php post_class(); ?>>
    <div class="posttitle">
    <h1><a href="<?php the_permalink(); ?>" rel="bookmark" title="<?php _e('Post');?> <?php the_ID(); ?> - <?php _e('permanent link');?>"><?php the_title();?></a></h1>
    Thread Starter Martin1982

    (@martin1982)

    Thanks for your help, but It creates additional title before category, smth is not ok.

    mkirkwag

    (@mkirkwag)

    I have a whole collection of themes downloaded from the wordpress site and not one of them has a loop.php file, nor is it an option in the wordpress theme editor. There seems to be a disconnect between what the expert coders are expecting to see and what we amateurs find. Any idea why this confusion exists?

    esmi

    (@esmi)

    and not one of them has a loop.php file

    Then you simply have a number of themes using slightly older templates. The loop.php template file was introduced in WordPress 3.0. See the Twenty Ten theme for an example.

    Thread Starter Martin1982

    (@martin1982)

    Anyone has a simple solution for my problem? Maybe i should change <h2> into <h1> and thats it?

Viewing 14 replies - 1 through 14 (of 14 total)
  • The topic ‘is missing’ is closed to new replies.