• I am trying to use this plugin for an image fade at the beginning of the content of my front page. it’s called Content Slide. I have the plugin installed and activated properly but now I have to add this small line of php code where I want the plugin to show up on the webpage: <?php if(function_exists('wp_content_slider')) { wp_content_slider(); } ?>
    I have looked through all of the folders on the website server and there is no index.php or header.php or any php files in the /wp-content/themes/energy_pros/ folder that seem to produce my actual website. the few index.php files i did find all have a small piece of php code that says “silence is golden”
    I don’t understand how to get this plugin going.

Viewing 4 replies - 1 through 4 (of 4 total)
  • this might help to locate the tempalte which generates the front page:

    https://codex.www.ads-software.com/Template_Hierarchy

    you could also try to edit the theme’s files with the dashboard – appearance – editor; see https://codex.www.ads-software.com/Editing_Files

    what theme are you using?

    Thread Starter MilkyTech

    (@milkytech)

    it is a custom theme based on Ashford or hero or both, i don’t know. Someone started this site and now I’ve been given the god awful task of figuring out wordpress and fixing the site.
    In the /wp-content/themes/ folder there is 4 theme folders and 1 index.php file that only contains “silence is golden”. The 4 theme folders are:
    ashford
    ashford_pro
    Energy_Pros
    placeholder

    i would think the file I need to add the code to is in the Energy_Pros folder, but there is no index.php in there, just function.php, meta-page.php and a bunch of post-blahblahblah.php’s. In-fact, I can’t figure for the life of me where any of the website is. if you go to the site energypros.com, there are like 10 webpages! where is all that data on the server? I have opened almost every .php file on the server in dreamweaver and none of them contain anything remotely resembling the visible site. sooo frustrating!

    energy_pros seems to be a child theme of ashford;

    so your site would use the templates from ashford unless they are duplicated into energy_pros.

    look into header.php or index.php in the asford theme for the right spot to add the code; then copy that file into the child theme folder (energy_pros) and edit it there.

    review how to work with child themes https://codex.www.ads-software.com/Child_Themes

    where is all that data on the server?

    most of it might be in the database

    Thread Starter MilkyTech

    (@milkytech)

    i tried that index.php and all that’s in there is this:

    <?php
    /**
     * Index
     *
     * Default home page blog
     *
     * v0.7 - Added php comments
     * v0.7 - Internationalized
     * v0.7 - Replaced default pagination with emm_paginate()
     * v2.0 - Remove sidebar for mobi
     * v2.1 - Fixed link
     * v2.3 - css grid class constant added
     * v2.3 - fixed mobi for child themes
     *
     * @author Tim Bednar
     * @version v1.0
    */
    ?>
    <?php get_header(); ?>
    
      <div id="content" class="<?php echo constant('ASHFORD_CONTENT_RIGHT_GRID');?>">
      <?php if(function_exists('wp_content_slider')) { wp_content_slider(); } ?>
        <?php if (have_posts()) : ?>
          <?php while (have_posts()) : the_post(); ?>
          <?php
            if(IS_MOBI=='false'){
              include (TEMPLATEPATH . '/post_excerpt.php');
            } else {
              include (ASHFORD_CHILD_DIR . '/post_list_mobi.php');
            }
          ?>
          <?php endwhile; ?>
        <?php else : ?>
          <?php  if (is_user_logged_in()){echo '<p class="hint"><a href="https://ashford.turtleinteractive.com/support" title="Get more hints">HINT &raquo;</a>: When you add more posts, they will be listed here. </p>';};?>
        <?php endif; ?>
        <?php if (function_exists("emm_paginate")) {
          emm_paginate();
        } else {?>
          <div id="paginate">
            <span class="paginate-previous"><?php next_posts_link('<span class="meta-nav">&laquo;</span> '.__('Older posts','ashford'), '10') ?></span>
            <span class="paginate-next"><?php previous_posts_link(__('Newer posts','ashford').'<span class="meta-nav">&raquo;</span>', '10') ?></span>
          </div>
        <?php }?>
      </div><!-- /#content -->
      <?php if (IS_MOBI=='false'){get_sidebar();} ?>
    <?php get_footer(); ?>

    You can see where I threw that line of code in at the start of the content div. I saved this file to the /themes/energy_pros/ folder and it didn’t work

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Can't find file to add php code’ is closed to new replies.