• Resolved margulies

    (@margulies)


    Hey all.

    I would like to insert a gateway onto the main index of my wordpress blog.

    The gateway site that generated this code for me says all I have to do is paste this code (below) right before the </head> tag.

    <script src=”https://adscendmedia.com/gatejs.php?aff=1972&prf=223&sid=&#8221; type=”text/javascript”></script><noscript>Enable Javascript to access this page. Powered by the Adscend Media Affiliate Network<meta http-equiv=”refresh” content=”0;url=https://adscendmedia.com/gateway_nojs.php”></noscript>

    However, since there is no index.HTML am I to assume that I need to be working with the index.php file instead?

    if so, this is the code for the index.php file when i’m in “Appearance editor” within wordpress:

    <?php get_header(); ?>

    <div class=”mainbody”>
    <div class=”leftcontent”>
    <?php $post = $posts[0]; // Hack. Set $post so that the_date() works. ?>
    <?php /* If this is a category archive */ if (is_category()) { ?>
    <h2 class=”pagetitle”>Archive for the ‘
    <?php single_cat_title(); ?>
    ’ Category</h2>
    <?php /* If this is a tag archive */ } elseif( is_tag() ) { ?>
    <h2 class=”pagetitle”>Posts Tagged ‘
    <?php single_tag_title(); ?>
    ’</h2>
    <?php /* If this is a daily archive */ } elseif (is_day()) { ?>
    <h2 class=”pagetitle”>Archive for
    <?php the_time(‘F jS, Y’); ?>
    </h2>
    <?php /* If this is a monthly archive */ } elseif (is_month()) { ?>
    <h2 class=”pagetitle”>Archive for
    <?php the_time(‘F, Y’); ?>
    </h2>
    <?php /* If this is a yearly archive */ } elseif (is_year()) { ?>
    <h2 class=”pagetitle”>Archive for
    <?php the_time(‘Y’); ?>
    </h2>
    <?php /* If this is an author archive */ } elseif (is_author()) { ?>
    <h2 class=”pagetitle”>Author Archive</h2>
    <?php /* If this is a paged archive */ } elseif (isset($_GET[‘paged’]) && !empty($_GET[‘paged’])) { ?>
    <h2 class=”pagetitle”>Blog Archives</h2>
    <?php } ?>
    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <div class=”post” id=”post-<?php the_ID(); ?>”>
    <div class=”posthead”>
    <div class=”date”>
    <?php the_time(‘d’, ”, ”); ?>
    <span class=”datemonth”>
    <?php the_time(‘M’, ”, ”); ?>
    </span></div>
    <h1 class=”posttitle”>” rel=”bookmark”>
    <?php the_title(); ?>
    </h1>
    <div class=”titlecomments”>
    <?php comments_popup_link(__(‘0 Comments’), __(‘1 Comment’), __(‘% Comments’)); ?>
    </div>
    </div>
    <div class=”thecontent”>
    <div class=”post_related”>
    <div class=”addthis”>
    <script type=”text/javascript”>
    addthis_url = location.href;
    addthis_title = document.title;
    addthis_pub = ‘3drockz’;
    </script>
    <script type=”text/javascript” src=”https://s7.addthis.com/js/addthis_widget.php?v=12&#8243; ></script>
    </div>
    </div>
    <div class=”innercontent”>
    <?php the_content(__(‘more…’)); ?>
    </div>
    <?php posts_nav_link(‘ ‘, __(‘? Previous Page’), __(‘Next Page ?’)); ?>
    <?php comments_template(); // Get wp-comments.php template ?>
    <div class=”postcategories”>Posted under: <?php printf(__(‘%6$s’),’Tags’,
    get_the_time(‘Y-m-d’),
    get_the_time(‘H:i:sO’),
    the_date(”, ”, ”, false),
    get_the_time(),
    get_the_category_list(‘, ‘),
    get_permalink(),
    wp_specialchars(get_the_title(), ‘double’),
    comments_rss() ) ?> </div>
    </div>
    </div>
    <?php endwhile; else: ?>
    <p class=”sorrydialog”>
    <?php _e(‘Sorry, no posts matched your criteria.’); ?>
    </p>
    <?php endif; ?>
    </div>
    <?php get_sidebar(); ?>
    </div>
    <?php get_footer(); ?>

    Or maybe I need to look at the index.php code by opening it up as a text document?

    Please help me paste this piece of code somewhere so it activates when people hit my main page:

    <script src=”https://adscendmedia.com/gatejs.php?aff=1972&prf=223&sid=&#8221; type=”text/javascript”></script><noscript>Enable Javascript to access this page. Powered by the Adscend Media Affiliate Network<meta http-equiv=”refresh” content=”0;url=https://adscendmedia.com/gateway_nojs.php”></noscript>

    Thankxx

Viewing 4 replies - 1 through 4 (of 4 total)
  • the </head> tag will be in your theme’s footer.php
    you can edit it directly in the admin by clicking on
    Appearance – Editor
    then clicking on the footer.php link in the right sidebar beside the editor

    Thread Starter margulies

    (@margulies)

    Really? that’s soo strange.

    Anyway, this is what I see in the footer:

    <div class=”footer”>
    <div class=”flickrrss”>
    <div class=”flickr_a”></div>
    <div class=”flickr_b”>
    <?php if (function_exists(‘get_flickrRSS’)) { get_flickrRSS(); } ?>
    </div>
    <div class=”flickr_c”></div>
    </div>
    <div class=”innerfooter”>Theme by Vision Team</div>
    </div>
    </div>
    </body></html>

    Now, where should I paste this code if the company told me to make sure to put it before the </head> of the header:

    <script src=”https://adscendmedia.com/gatejs.php?aff=1972&prf=223&sid=&#8221; type=”text/javascript”></script><noscript>Enable Javascript to access this page. Powered by the Adscend Media Affiliate Network<meta http-equiv=”refresh” content=”0;url=https://adscendmedia.com/gateway_nojs.php”></noscript>

    ???

    Thread Starter margulies

    (@margulies)

    Nevermind I got it thanks!

    Hi !!
    Can you tell me how you fix that please ?

    I have the same problem !!

    Thanks

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Copy and Paste HTML code to index.php? (Posted Again b/c of Phantom post)’ is closed to new replies.