Last active
January 29, 2017 17:14
-
-
Save wpperform/4416749 to your computer and use it in GitHub Desktop.
Changes to Yet Another Related Posts Plugin to support templates in plugin templates folder instead of theme folder
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// 5 changes to /classes/YARPP_Core.php for version 4.3.6 | |
// each change involves commenting out 1 line and replacing with revised version | |
// near line 489 | |
// $this->templates = glob(STYLESHEETPATH . '/yarpp-template-*.php'); | |
$this->templates = glob(YARPP_DIR . '/yarpp-templates' . '/yarpp-template-*.php'); | |
// near line 1121 | |
// } else if ((bool) $template && file_exists(STYLESHEETPATH.'/'.$template)) { | |
} else if ((bool) $template && file_exists(YARPP_DIR . '/yarpp-templates/' . $template)) { | |
// near line 1124 | |
// include(STYLESHEETPATH . '/' . $template); | |
include(YARPP_DIR . '/yarpp-templates/' . $template); | |
// near line 1309 | |
// } else if ((bool) $template && file_exists(STYLESHEETPATH.'/'.$template)) { | |
} else if ((bool) $template && file_exists(YARPP_DIR . '/yarpp-templates/' . $template)) { | |
// near line 1313 | |
// include(STYLESHEETPATH . '/' . $template); | |
include(YARPP_DIR . '/yarpp-templates/' . $template); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment