Results 1 to 10 of 1859

Threaded View

  1. #11
    Join Date
    Mar 2011
    Location
    Pensacola, FL
    Posts
    88
    Plugin Contributions
    4

    Default Re: Wordpress On ZC [Support Thread]

    Possibly there should be a support thread specifically for WOZ sideboxes only module and/or combining it with the numinix solution.

    I recently submitted an updated version of the module, the tpl_wp_XXX pages to which are added one line that seemed to be needed to close a DIV. Maybe this is only necessary when using the numinix method.

    Code:
      $content .= '</div>';
    below

    Code:
      $content .= '<div id="' . str_replace('_', '-', $box_id . 'Content') . '" class="sideBoxContent">';
      $content .= '<ul>'.$out.'</ul>';
    The extra-configures/wordpress_config.php file also needed to be changed. A 404 file not found error was occurring on the blog pages, which seemed to be due to something in here:
    Code:
    		define('WP_USE_THEMES', true);
    		$wp_did_header = true;
                    require_once(ABSPATH.'wp-config.php');
    It worked fine when that code was removed, but there was a sidebox error on the NON-blog pages.

    So I updated the code on the extra-configures/wordpress_config.php page to:

    Code:
    define ('ABSPATH','/path/to/my/blog/');
    
    $host = $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI'];
    $its_blog_page = $_SERVER['SERVER_NAME'] . "/blog";
    
    if ((strpos($host, $its_blog_page) !== false) && (file_exists(ABSPATH.'wp-config.php'))){
    	$woz_install=1;
    	}else{
    		$woz_install=1;
    		define('WP_USE_THEMES', true);
    		$wp_did_header = true;
    		require_once(ABSPATH.'wp-config.php'); 
    	}
    which simply checks the current URL to see if it contains the numinix-style path to the blog (mydomain.com/blog) and loads ONLY the $woz_install=1; line, otherwise for any other page it loads also the WP THEME, wp Header and WP config lines.

    I imagine there as a much more elegant way to do this and I would love to see if if anyone's inspired to share. Otherwise, hope this is useful.
    Last edited by mutinyzoo; 18 Nov 2013 at 10:36 PM.

 

 

Similar Threads

  1. EasyPopulate 4.0 Support Thread
    By chadderuski in forum Addon Admin Tools
    Replies: 3657
    Last Post: 3 Jan 2025, 12:04 AM
  2. WordPress® for Zen Cart® (wp4zen) [Support Thread]
    By DivaVocals in forum All Other Contributions/Addons
    Replies: 109
    Last Post: 1 Dec 2024, 01:36 PM
  3. Hebrew Support - latest release [Support Thread]
    By eranariel in forum Addon Language Packs
    Replies: 19
    Last Post: 23 Jan 2023, 08:04 AM
  4. PurpleShades Support Thread
    By kobra in forum Addon Templates
    Replies: 122
    Last Post: 18 May 2011, 07:18 PM
  5. ZJ Black 2 support thread
    By Liamv in forum Addon Templates
    Replies: 1
    Last Post: 15 Feb 2010, 02:53 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR