[Solved] Where to insert hardcode to display slideshow in home page?

Hi,

I have pasted it into index.php file inside my theme folder

<pre lang="php">
<?php
/**
 * @package WordPress
 * @subpackage Enfinity
 */

get_header(); ?>

<section class="pix_content_990">
   <?php if (function_exists('slideshow')) { slideshow($output = true, $post_id = false, $gallery_id = false, $params = array()); } ?>
    <div class="pix_content_960">
</pre>


so gallery was displayed in "blog" page, below the menu bar, when "blog" page was also front page.

Then, I selected "home" as front page, but gallery is still dispayed on "blog" page.

Blog with gallery: http://mavoshirts.com/blog/

How to solve this issue?

Sorry for my bad English.

Comments

  • 5 Comments sorted by
  • Vote Up0Vote Down
    Hi,

    You would have to paste the code into the template file that "home" is using to display the page, e.g. home.php (or whichever file it's using).

    I hope that helps? Please let us know, will you?

    Regards,

    Phil
  • Vote Up0Vote Down
    Hi phil,

    thank you for reply.

    Unfortunately, I don't know the file that home is using, no home.php into theme folder.

    Regards.
  • Vote Up0Vote Down
    Thank you for your response.

    The blog must be using the index.php template file.
    Best is to ask the author/developer of this theme what the template file for the home page is.
    If the home page is just a regular page, the template file is most likely page.php to use.

    But if you hardcode into page.php it will display on all pages.
    So you can use a condition is_front_page() to only show on the home page.

    Let me know if this helps please!
  • Vote Up0Vote Down
    Hi,

    thank you for reply.

    I asked the theme author, as you advised, so hardcoded into widepage.php without any condition and now it work fine.
    Slideshow displays on home page only.

    Thank you!
  • Vote Up0Vote Down
    Thank you for your response.

    I'm glad to hear that you managed to get this working.

    Let us know if you need any further assistance please!
Sign In or Register to comment.