From 455d3cbf96fe18f193fe155d0223939839bbaf2b Mon Sep 17 00:00:00 2001 From: modela bitweaver Date: Tue, 2 Feb 2021 01:12:19 -0500 Subject: move _inc and _lib to includes/ and use PKG_INCLUDE_PATH constants --- admin/wp-migrate.php | 2 +- blogs_rss.php | 2 +- includes/classes/BitBlog.php | 2 +- includes/classes/BitBlogPost.php | 6 +++--- includes/display_bitblogpost_inc.php | 2 +- includes/lookup_blog_inc.php | 2 +- includes/lookup_post_inc.php | 2 +- liberty_plugins/data.blog.php | 2 +- print_blog_post.php | 2 +- send_post.php | 2 +- 10 files changed, 12 insertions(+), 12 deletions(-) diff --git a/admin/wp-migrate.php b/admin/wp-migrate.php index 7bd1a9a..7d64e47 100644 --- a/admin/wp-migrate.php +++ b/admin/wp-migrate.php @@ -22,7 +22,7 @@ require_once( '../../kernel/setup_inc.php' ); //require_once(USERS_PKG_PATH.'RoleUser.php'); require_once(BLOGS_PKG_CLASS_PATH.'BitBlog.php'); require_once(BLOGS_PKG_CLASS_PATH.'BitBlogPost.php'); -require_once(LIBERTY_PKG_PATH.'LibertyComment.php'); +require_once(LIBERTY_PKG_CLASS_PATH.'LibertyComment.php'); $gBitSystem->verifyPermission( 'p_admin' ); diff --git a/blogs_rss.php b/blogs_rss.php index a70541e..858e98d 100644 --- a/blogs_rss.php +++ b/blogs_rss.php @@ -15,7 +15,7 @@ $gBitSystem->verifyPackage( 'blogs' ); $gBitSystem->verifyFeature( 'blogs_rss' ); require_once( BLOGS_PKG_CLASS_PATH.'BitBlogPost.php' ); -require_once( RSS_PKG_PATH."rss_inc.php" ); +require_once( RSS_PKG_INCLUDE_PATH.'rss_inc.php' ); // default feed info $rss->title = $gBitSystem->getConfig( 'blogs_rss_title', $gBitSystem->getConfig( 'site_title' ).' - '.tra( 'Blog Posts' ) ); diff --git a/includes/classes/BitBlog.php b/includes/classes/BitBlog.php index 87a5708..9f360e9 100644 --- a/includes/classes/BitBlog.php +++ b/includes/classes/BitBlog.php @@ -9,7 +9,7 @@ * required setup */ require_once( BLOGS_PKG_CLASS_PATH.'BitBlogPost.php'); -require_once( LIBERTY_PKG_PATH.'LibertyComment.php'); +require_once( LIBERTY_PKG_CLASS_PATH.'LibertyComment.php'); define( 'BITBLOG_CONTENT_TYPE_GUID', 'bitblog' ); diff --git a/includes/classes/BitBlogPost.php b/includes/classes/BitBlogPost.php index a79adbc..280893d 100644 --- a/includes/classes/BitBlogPost.php +++ b/includes/classes/BitBlogPost.php @@ -20,8 +20,8 @@ /** * required setup */ -require_once( LIBERTY_PKG_PATH.'LibertyComment.php'); -require_once( LIBERTY_PKG_PATH.'LibertyMime.php'); +require_once( LIBERTY_PKG_CLASS_PATH.'LibertyComment.php'); +require_once( LIBERTY_PKG_CLASS_PATH.'LibertyMime.php'); require_once( BLOGS_PKG_CLASS_PATH.'BitBlog.php'); define( 'BITBLOGPOST_CONTENT_TYPE_GUID', 'bitblogpost' ); @@ -725,7 +725,7 @@ class BitBlogPost extends LibertyMime { $parts = parse_url($_SERVER['REQUEST_URI']); $uri = httpPrefix(). str_replace('post', 'view_post', $parts['path']). '?post_id=' . $this->mPostId . '&blog_id=' . $this->mInfo['blog_id']; - include_once ( UTIL_PKG_INC.'Snoopy.class.inc' ); + include_once ( UTIL_PKG_INCLUDE_PATH.'Snoopy.class.inc' ); $snoopy = new Snoopy; foreach ($tracks as $track) { diff --git a/includes/display_bitblogpost_inc.php b/includes/display_bitblogpost_inc.php index 7dd7859..266d725 100644 --- a/includes/display_bitblogpost_inc.php +++ b/includes/display_bitblogpost_inc.php @@ -67,7 +67,7 @@ if ( empty( $_REQUEST['format'] ) || $_REQUEST['format'] == "full" || $_REQUEST[ if ($gBitSystem->isFeatureActive( 'blog_posts_comments' ) ) { $comments_return_url = $_SERVER['SCRIPT_NAME']."?post_id=".$gContent->mPostId; $commentsParentId = $gContent->mContentId; - include_once ( LIBERTY_PKG_PATH.'comments_inc.php' ); + include_once ( LIBERTY_PKG_INCLUDE_PATH.'comments_inc.php' ); } $extendedTitle = isset($gContent->mInfo['blogtitle']) ? ' - '.$gContent->mInfo['blogtitle'] : NULL; $gBitSystem->setBrowserTitle($gContent->mInfo['title'].$extendedTitle); diff --git a/includes/lookup_blog_inc.php b/includes/lookup_blog_inc.php index bf1d41f..fa384dd 100644 --- a/includes/lookup_blog_inc.php +++ b/includes/lookup_blog_inc.php @@ -9,7 +9,7 @@ */ global $gContent; require_once( BLOGS_PKG_CLASS_PATH.'BitBlog.php' ); -require_once( LIBERTY_PKG_PATH.'lookup_content_inc.php' ); +require_once( LIBERTY_PKG_INCLUDE_PATH.'lookup_content_inc.php' ); // if we already have a gContent, we assume someone else created it for us, and has properly loaded everything up. if( empty( $gContent ) || !is_object( $gContent ) || !$gContent->isValid() ) { diff --git a/includes/lookup_post_inc.php b/includes/lookup_post_inc.php index 12d52ce..0803a4e 100644 --- a/includes/lookup_post_inc.php +++ b/includes/lookup_post_inc.php @@ -9,7 +9,7 @@ */ global $gContent; require_once( BLOGS_PKG_CLASS_PATH.'BitBlogPost.php'); -require_once( LIBERTY_PKG_PATH.'lookup_content_inc.php' ); +require_once( LIBERTY_PKG_INCLUDE_PATH.'lookup_content_inc.php' ); if( empty( $gContent ) || !is_object( $gContent ) || !$gContent->isValid() ) { // if blog_id supplied, use that diff --git a/liberty_plugins/data.blog.php b/liberty_plugins/data.blog.php index cc5535d..4741845 100644 --- a/liberty_plugins/data.blog.php +++ b/liberty_plugins/data.blog.php @@ -88,7 +88,7 @@ function data_blog($data, $params) { // No change in the parameters with Clyde $pluginParams = $gLibertySystem->mPlugins[PLUGIN_GUID_DATABLOG]; require_once( BLOGS_PKG_CLASS_PATH.'BitBlog.php'); - require_once( LIBERTY_PKG_PATH.'lookup_content_inc.php' ); + require_once( LIBERTY_PKG_INCLUDE_PATH.'lookup_content_inc.php' ); $module_params = $params; diff --git a/print_blog_post.php b/print_blog_post.php index c970db0..256a8a6 100644 --- a/print_blog_post.php +++ b/print_blog_post.php @@ -60,7 +60,7 @@ $gBitSystem->verifyPermission( 'p_blogs_view' ); if ($gBitSystem->isFeatureActive( 'blog_posts_comments' )) { $comments_return_url = $_SERVER['SCRIPT_NAME']."?post_id=".$gContent->getField( 'post_id' ); $commentsParentId = $gContent->mContentId; - include_once ( LIBERTY_PKG_PATH.'comments_inc.php' ); + include_once ( LIBERTY_PKG_INCLUDE_PATH.'comments_inc.php' ); } diff --git a/send_post.php b/send_post.php index 705e15b..f6e8fd2 100644 --- a/send_post.php +++ b/send_post.php @@ -57,7 +57,7 @@ if ($gBitSystem->isFeatureActive( 'blog_posts_comments' )) { $commentsParentId = $gContent->mContentId; $comments_prefix_var = 'post:'; $comments_object_var = 'post_id'; - include_once ( LIBERTY_PKG_PATH.'comments_inc.php' ); + include_once ( LIBERTY_PKG_INCLUDE_PATH.'comments_inc.php' ); } if (!isset($_REQUEST['addresses'])) { -- cgit v1.3