![]() |
Which WP function do I need to display certain things includes on the main page only?
I've got a few things I have added into my site. That are using <?php include> tags.
One is in sidebar.php / one is in footer.php etc. Problem is I only want to display these includes on the main page. What's the best way to do it? |
Quote:
PHP Code:
PHP Code:
Here's a good way to pick out certain categories (for picking out and advertising only gay sites on gay/tranny as per this example) PHP Code:
|
what jdoughs said
|
Thanks J :thumbsup
I remember you posting something about it before, but couldn't find the thread. This should work perfectly |
what is it you wanna only display on home?
|
Quote:
Going to try it out in a second. Will report back with my result :thumbsup |
Have any of you guys seen a plugin that will let you put links only in certain categories? I looked real quick the other day but didn't see anything.
|
Quote:
PHP Code:
|
Ok it definately works. but wouldn't work with a php include unless I done it wrong.
Here is what i tried below: <?php wp_reset_query(); if (is_home() ) { echo '<?php include "/include.html"; ?>'; } ?> Unless I have to put the full file location in there. will try that now. |
Code:
<?php |
Quote:
Code:
<?php if ( is_home() ) : ?> |
All times are GMT -7. The time now is 10:09 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc