1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Need your help on Wordpress blog

Discussion in 'HTML & Website Design' started by jones1982, Aug 19, 2013.

  1. #1
    Question to only wordpress or web developer experts = I've a wordpress site developed by one developer www.omegaweb.com but now I'm facing a problem. I just can't edit home page. when I do: dashboard > appearance > editor then I see there are 7 index.php files! it should be one ... right? I would like to add adsense code top of the blog entry (not on single page(I've done), I like to add on home page). please see photo that I've added & tell me which file I need to edit for home page?
    [​IMG]
     
    jones1982, Aug 19, 2013 IP
  2. rajku

    rajku Member

    Messages:
    37
    Likes Received:
    3
    Best Answers:
    1
    Trophy Points:
    33
    #2
    Check out this image it will help. http://codex.wordpress.org/images/1/18/Template_Hierarchy.png
    The above image gives you how default wordpress works. But a theme developer can make complicated things, as to what file is required for a particular page to work, in addition to the default ones. Try your luck with index.php also you will need to do conditional stuff to show only on home page (front page).
    <?php if( is_front_page() ) {?>
    ADSENSE CODE
    <?php }?>
    Code (markup):
     
    rajku, Aug 19, 2013 IP
  3. matt_62

    matt_62 Prominent Member

    Messages:
    1,827
    Likes Received:
    515
    Best Answers:
    14
    Trophy Points:
    350
    #3
    ok... 7 index.php is something that I have never heard of before.
    Normally, you could edit the header file, though I think that the header will finish at the menu, and you might not be able to include it in their.

    if its a standard sort of theme, there should be Main Index Template, and page template, and in here at the top is where your ad code should go.
     
    matt_62, Aug 19, 2013 IP