Maybe we need a bit more context regarding the code you put in..
In the above case, i’m wondering what the very first line of PHP is doing, since you arn’t gettimg whats inside of this php ELSE clause…
it’s what’s default in the theme
does that affect whtether or not my html works?
I think the html tags are already assumed by the template processor.
Just like the html on the 2nd line of your code chuck above:
<div id="container">
does not need to be wrapped in <html> tags, neither does any of your html code.
Ah, so to put in more html within this chunk of code :
<?php else : ?>
<div id="container">
<?php get_template_part( 'loop', 'index' ); ?>
<?php get_sidebar(); ?>
<div class="clear"></div>
</div><!-- #container -->
<?php endif; ?>
It would look like this:
<?php else : ?>
<div id="container">
<?php get_template_part( 'loop', 'index' ); ?>
<?php get_sidebar(); ?>
<div class="clear"></div>
</div><!-- #container -->
<div id="newchunkofhtml">
<a href="#">any type of html goes here</a>
</div>
<?php endif; ?>
All that code:
<div id="newchunkofhtml">
<a href="#">any type of html goes here</a>
</div>
can of course be changed into what ever – except <html> and <body> tags and other overall-structual tags, since you are already inside an html page.
However the entire code you have shown won’t be shown unless the ELSE parameter is TRUE..
Makes sense ?
Np
Mark as resolved please 😉