New Plugin: “Directory” - Create a full blown directory site.

Description:
The “Directory” plugin gives you the ability to create a full blown directory site. At its core it uses the “Content Types” submodule introduced with CustomPress which gives you the ability to control all of your custom post types, taxonomies and fields. The “Directory” plugin, uses custom taxonomies for its top categories. You can add as many taxonomies as you want. Each taxonomy can be extended by adding categories and sub-categories inside it. Using this method you can create extremely well organized directory with perfect URL structure.

The “Directory” plugin package comes with a default theme. It can be found inside “directory/dp-themes/dp-default” directory. You can use it straight from the plugin or if you want to customize it you can copy it to your “themes” directory and do your customizations there. Speaking of customization the theme comes with theme options for “Background” and “Colors”. You can find these options inside your WP-ADMIN panel under the top level menu “Appearance”. With these options you can control almost any presentation aspect from the default theme.

The “Directory” plugin also comes with the “PayPal Express” payment gateway integrated. You can set up you API credential and can begin chragin your users for listing submission. The plugin also offer a header banner space which can be managed from the back-end.

For the novice users, the plugin comes with 16 base preconfigured taxonomies which you can import at will. You can also import an example Custom Field. Using the “Custom Fields” functionality of the Content Types submodule you can extend your listings however you like – text-fields, text-areas, check-boxes, radio buttons, drop-downs and more.

Features:
1.Add/edit/remove post types, taxonomies and custom fields.
2.Default theme with options for “Background” and “Colors”
3.Preconfigured Taxonomies and Custom Fields ( you can import at will )
4.Header banner advertising management
5.Cost of Service / Terms of Service management
6.PayPal Express payment gateway

Installation:
1.Extract the plugin archive file.
2.Copy the “directory” folder inside “wp-content/plugins” directory
3.Go to your WP-ADMIN Plugins page and activate the plugin.

Compatibility:
WordPress, WordPress MS ( 3.0.1 )

Changelog:
Version: 1.0.5
Initial release.

Release Notes:
This is the initial release of the "Directory" plugin. It is thoroughly tested in-house but not with real users, so you may expect some bugs under unusual circumstances. Please report all bugs in the current thread.

Screenshot:

  • member1
    • The Incredible Code Injector

    Thanks Ivan.
    Looking forward to testing this one out!

    I've activated the plugin on one of my multisite blogs. (ie - not network activated) blogid 32.

    Here's some early issues.
    Cant Import Custom taxonimies and Fields
    This not having any effect. No tables or entries in the database. Nothing in the Content Types area of the backend.

    Theme
    If I want to keep my existing theme, how can I set this up?

    In house theme 'Appearance' changes:
    Change to background colour not working. Colour isn't overwriting the bg image.

  • member1
    • The Incredible Code Injector

    Membership Plugin integration.
    I know it's very early days, but I'd like to ask the question about the integration of Directory with Membership plugin.

    Its probably on your radar, and I understand the need to bed down Directory as a stand alone option first, but I think that the 'Integration with Membership' option should be added to all of the core functionality plugins that wpmudev provides.

    thanks

  • Aphrodite
    • The Reaper

    mmmm

    Well first I suppose that the theming will be available on official tag no ? For now it does not fit in other themes installed.

    1- Well, I am not really familiar with custom post types and custom fields, is there a kind of tutorial to use it ?

    2 - how to just suppress the bkg image and let a color ? I chosse a color but the bkg image still remain :slight_smile:

    3 - a free submission + payed upgrade is on plan ?

  • Ivan
    • The Incredible Code Injector

    @member1, @guntur, @Aphrodite

    member1:

    I've activated the plugin on one of my multisite blogs. (ie - not network activated) blogid 32.
    If the Directory plugin is only activated on a single blog in a multisite install, are there any special config options to define the blog id?

    The current version works on root level only ( SS/MS ). We are currently working on making it root level independent ( the way you want to use it ).

    member1:

    Cant Import Custom taxonimies and Fields

    Related to the above point.

    member1:

    If I want to keep my existing theme, how can I set this up?

    gunter:

    I've installed this plugin and I also wonder if I want to keep my existing theme and make the Directory appear as one of the pages in my main menu, how do I do that?

    Aphrodite:

    Well first I suppose that the theming will be available on official tag no ? For now it does not fit in other themes installed.

    Open the “dp-themes/dp-default/includes” directory. Inside the file “theme-setup.php” you will find theme specific functions. All functions with “category” inside them are responsible for outputting the taxonomies. You can copy them into your theme and customize them. For next versions, I will try to make the theme customization API as user friendly as possible. The bleeding edge users however are required to get their hands dirty a little bit.

    member1:

    Change to background colour not working. Colour isn't overwriting the bg image.

    Aphrodite:

    How to just suppress the bkg image and let a color ? I chosse a color but the bkg image still remain

    Bug. Will be fixed in the next minor release.

    member1:

    Membership Plugin integration.
    I know it's very early days, but I'd like to ask the question about the integration of Directory with Membership plugin.
    Its probably on your radar, and I understand the need to bed down Directory as a stand alone option first, but I think that the 'Integration with Membership' option should be added to all of the core functionality plugins that wpmudev provides.

    Aphrodite:

    a free submission + payed upgrade is on plan

    It is on our radar.

    Aphrodite:

    Well, I am not really familiar with custom post types and custom fields, is there a kind of tutorial to use it ?

    Check CustomPress's Description and Guides, they apply here as well - https://premium.wpmudev.org/forums/topic/new-plugin-custompress-custom-post-taxonomy-and-field-manager

  • drdave
    • The Crimson Coder

    If anyone thought of doing this with my type of setup beware!

    I tried it on a test site with buddypress 1.2.6 and bp-daily 3.8.1 and this new theme kidnapped my existing theme. I have no problems with this though as it was just a quick (risky nonetheless) test due to lack of time.

    However, when I removed it, deleted the directory plugin folder, everything was back to normal.

    When I have more time I will do it right the next time. :slight_smile:

    This last post seem to answer my question but then again it does not appear to be compatible with Buddypress.

    Compatibility:
    WordPress, WordPress MS ( 3.0.1 )

  • member1
    • The Incredible Code Injector

    Thanks for your replies Ivan.

    The current version works on root level only ( SS/MS ). We are currently working on making it root level independent ( the way you want to use it ).

    Some feedback:
    From an end-user point of view I really don't understand why 'making it root level independent isn't built in from the start for all wpmudev plugins. WPMUDev is the holy grail of multisite after all :slight_smile:

    It seems like often when a new plugin is released, that the expectation is that it must take over control of the root blog. (see: Membership, MarketPress, Classifieds) This is fine if you are going to build a new site around the new functionality each time but it's just not practical at all if you are using the plugin to add more functionality to an existing site.

    I love the service you guys provide. I'm just offering suggestions to help make it better.
    In the meantime I'll move Directory to the back of the testing/development queue and wait for future releases.

  • Marty Thornley
    • Site Builder, Child of Zeus

    I am not really clear on the root level vs single blog here... I understand what that means but how does that effect the directory?

    Does the directory need to be the whole blog? Or can this be used to add a directory page or section to an existing main site?

    Either way, sounds great and will be testing soon.

  • Ivan
    • The Incredible Code Injector

    @member1

    From an end-user point of view I really don't understand why 'making it root level independent isn't built in from the start for all wpmudev plugins. WPMUDev is the holy grail of multisite after all :slight_smile:

    It seems like often when a new plugin is released, that the expectation is that it must take over control of the root blog. (see: Membership, MarketPress, Classifieds) This is fine if you are going to build a new site around the new functionality each time but it's just not practical at all if you are using the plugin to add more functionality to an existing site.

    I love the service you guys provide. I'm just offering suggestions to help make it better.
    In the meantime I'll move Directory to the back of the testing/development queue and wait for future releases.

    If you want the short answer - Its not that easy. Working with sub-sites brings whole another level of complexity to the picture. Large parts of the functionality have to be sub-site specific ( we are talking user capabilities, rewrite rules, database options, you name it ). If we try to integrate everything from the start the bug reports will be quite big, therefore we first focus on making all the functionality work on SS and root level MS, we resolve all the pending issues, create a stable release and then we add the extra layer which supports sub-sites.

    Fear not however, the next versions of Directory and Classifieds will work on sub-sites and you can expect them very soon.

    @Marty Thornley

    I am not really clear on the root level vs single blog here... I understand what that means but how does that effect the directory?

    Does the directory need to be the whole blog? Or can this be used to add a directory page or section to an existing main site?

    You can use the Directory listings on sub-sites ( just like regular posts ) but some of the plugin features are root level specific - like the payment gateway, ads etc.

  • myork
    • WPMU DEV Initiate

    Question: With the directory plugin, is it possible to have the listings in a heading be randomized on each page load in a heading? Then If someone has paid, their listing would be consistent. Also, can you control positioning by payment in headings?

  • Ivan
    • The Incredible Code Injector

    @myork

    With the directory plugin, is it possible to have the listings in a heading be randomized on each page load in a heading? Then If someone has paid, their listing would be consistent. Also, can you control positioning by payment in headings?

    You can use standard WordPress functions to shuffle/output the listings inside "loop-directory.php" - query_posts for example. By default, all listing submissions are behind a paywall, once you have paid you get a registration with the site and you can submit listings. You can play around with the code and you can get what you are looking for by customizing the "loop-directory.php".

  • JoseffB
    • The Crimson Coder

    In a single install got error:

    Fatal error: Cannot redeclare ct_load_plugin_textdomain() (previously declared in /home/content/82/4558682/html/itfp/wp-content/plugins/core-cp/cp-submodules/content-types/ct-loader.php:46) in /home/content/82/4558682/html/itfp/wp-content/plugins/directory/dp-submodules/content-types/ct-loader.php on line 48

    Also Membership plugin not working (maybe it's MU only?)

  • Ivan
    • The Incredible Code Injector

    @Joseff Am, looking at your error paths I see you are using both CustomPress and Directory on a single install an since they use the same modules ( unfortunately without checking if function exists ) you get the error. Deactivate CustomPress and you will no longer receive the error. In the next release there will be support for both plugins on a single install.

    @Johan Go to your Settings -> Permalinks and resave your permalink structure, this will force WordPress to flush the rewrite rules and it will fix your problem.

  • drmike
    • DEV MAN’s Mascot

    Natetronn, welcome to wpmudev.

    They really need to know what the specific error you;re receiving is. Please check your webserver's error logs and copy and paste out of there. Most support forums operate in such a manner and it;s always a plus to provide specifics. The specific versions of all of three scripts mentioned would also be a plus.

  • Ivan
    • The Incredible Code Injector

    @Natetronn

    Seems you get an error if you already have custompress activated. It would be nice if this could be imported into custompress for those of us who have other custom types.

    Yes, Joseff found the same bug. Quick fix: Open "directory" plugin folder and edit "dp-loader.php". Comment out Line 61:
    // include_once 'dp-submodules/content-types/ct-loader.php';

  • justin-madigan
    • Flash Drive

    I am glad that wpmu dev finally has a directory plugin. However, I am not happy with the route taken in terms of its functionality. There is already a decent enough directory-theme with DirectoryPress. I was hoping that this would actually be a plugin but it essentially just highjacks your theme and takes over the entire installation. Many people want to have a directory as an addon to their site just how forums work. Is there any chance that this plugin can be used in this way or any chance that future development may bring it in this direction? Thanks.

    - Justin

  • Ivan
    • The Incredible Code Injector

    @justin-madigan Yes, the current version is the first one released into the wild and they are certainly a lot of things that need to be improved. We have an open discussion internally about the improvements we all want to see in the next release. We will take your thoughts along with all other suggestions from peeps in the forum into consideration.

    On your thoughts about the functionality - you can deactivate the default theme and use the functions inside "dp-default/includes" to customize your own theme. The default one is just an example on how things are wired together. The core stuff is theme independent.

  • niwniw
    • New Recruit

    Hi
    Like the directory, so far, installed easily enough, added custom fields (text and Drop Down Select Box)
    text fields appear OK but am getting this error on Drop Down selected field

    Warning: Invalid argument supplied for foreach() in /home/onlineha/public_html/wp-content/plugins/directory/dp-themes/dp-default/single.php on line 51

    anyone else seen this ?
    thanks

  • galaxy5
    • Design Lord, Child of Thor

    Does this plugin enable location based search for example.

    I want to look for all Computer Technicians in Town A, B, C

    Would it be capable of showing all the Profile of Computer Technicians in Town A, B and C and surrounding suburbs or does it need to be extended to include this feature with the integration of google maps.

  • Ivan
    • The Incredible Code Injector

    @niwniw Can you please show me the embed code you are using in single.php

    @midwestbonsai We are working on it :wink:

    @galaxy5 Add Computer Technicians as taxonomy and Town A,B,S as terms, so each term will show all of the entries with it. Next version will also have gmaps integrated.

    @Johan The new version of Classifieds we are releasing soon will have a lot of the features of directory but with front-end gui. Directory will also be updated in the next release.

  • niwniw
    • New Recruit

    re:From Ivan -can you show me the embed code
    the URL
    http://www.onlinehardwareshop.com/blog/listing/united-mitre-10-home-and-trade-3/

    The single.php code

    <?php
    /**
     * The Template for displaying all single posts.
     */
    
    get_header(); ?>
    
    		<div id="container">
    			<div id="content" role="main">
    
    <?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
    
    				<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
    					<h1 class="entry-title"><?php the_title(); ?></h1>
    
    					<div class="entry-meta">
    						<?php dp_posted_on(); ?>
    					</div><!-- .entry-meta -->
    					<div class="entry-content">
                            <?php the_post_thumbnail( array( 275, 100 ), array( 'class' => 'alignleft' ) ); ?>
    						<?php the_content(); ?>
                            <?php _e( 'Website URL', 'directory'); ?>:
                            <a href="<?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?>"><?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?></a>
                            <br /><br />
    						<?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', 'directory' ), 'after' => '</div>' ) ); ?>
    
    					</div><!-- .entry-content -->
    
    <?php if ( get_the_author_meta( 'description' ) ) : // If a user has filled out their description, show a bio on their entries  ?>
    					<div id="entry-author-info">
    						<div id="author-avatar">
    							<?php echo get_avatar( get_the_author_meta( 'user_email' ), 60 ); ?>
    						</div><!-- #author-avatar -->
    						<div id="author-description">
    							<h2><?php printf( esc_attr__( 'About %s', 'directory' ), get_the_author() ); ?></h2>
    							<?php the_author_meta( 'description' ); ?>
    							<div id="author-link">
    								<a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>">
    									<?php printf( __( 'View all posts by %s <span class="meta-nav">&rarr;</span>', 'directory' ), get_the_author() ); ?>
    								</a>
    							</div><!-- #author-link	-->
    						</div><!-- #author-description -->
    					</div><!-- #entry-author-info -->
    <?php endif; ?>
    
    <?php echo get_post_meta( $post->ID, '_ct_text_4ccc5fd023950', true ); ?><br />
    <?php if ( get_post_meta( $post->ID, '_ct_selectbox_4cf582aeccc82', true )) { foreach ( get_post_meta( $post->ID, '_ct_selectbox_4cf582aeccc82', true ) as $value ) { echo $value . ', '; }}?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf583d5ee194', true ); ?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf583f39539c', true ); ?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf5840798012', true ); ?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf5841f125e6', true ); ?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf58453af084', true ); ?><br />
    <?php echo get_post_meta( $post->ID, '_ct_text_4cf584668a366', true ); ?><br />
    <?php if ( get_post_meta( $post->ID, '_ct_selectbox_4cf5852d27b67', true )) { foreach ( get_post_meta( $post->ID, '_ct_selectbox_4cf5852d27b67', true ) as $value ) { echo $value . ', '; }} ?>
    <?php if ( get_post_meta( $post->ID, '_ct_selectbox_4cf585673a48a', true )) { foreach ( get_post_meta( $post->ID, '_ct_selectbox_4cf585673a48a', true ) as $value ) { echo $value . ', '; }} ?>
    
    					<div class="entry-utility">
    						<?php dp_posted_in(); ?>
    						<?php edit_post_link( __( 'Edit', 'directory' ), '<span class="edit-link">', '</span>' ); ?>
    					</div><!-- .entry-utility -->
    				</div><!-- #post-## -->
    
    				<?php comments_template( '', true ); ?>
    
    <?php endwhile; // end of the loop. ?>
    
    			</div><!-- #content -->
    		</div><!-- #container -->
    
    <?php // get_sidebar(); ?>
    <?php get_footer(); ?>
  • Marty McOmber
    • Design Lord, Child of Thor

    So happy you guys created this. I will need to wait until it is stable for use on a subblog. My other questions are

    Does it include and ability to rate listings out of the box, or can it work with a rating plug in?

    Can you charge for featured listings?

    And I assume that comments will work with this, giving readers a chance to report their experiences with the listed business?

    Thanks!

  • Ivan
    • The Incredible Code Injector

    @niwniw Put "is_array()" - http://php.net/manual/en/function.is-array.php check around the foreach containing embed codes. Example:

    if ( is_array( get_post_meta( $post->ID, '_ct_selectbox_4cf5852d27b67', true ) ) ) {
    foreach ( get_post_meta( $post->ID, '_ct_selectbox_4cf5852d27b67', true ) as $value ) {
    echo $value . ', ';
    }
    }

    @Marty McOmber

    Does it include and ability to rate listings out of the box, or can it work with a rating plug in?

    This can be achieved with additional plugin, the Directory plugin works with post types so any plugin should work.

    Can you charge for featured listings?

    Currently you charge for all the listing or you don't charge at all, but you can easily customize your setup to do what you want.

    And I assume that comments will work with this, giving readers a chance to report their experiences with the listed business?

    Yes everything is build on top of custom post types so everything that applies to post is included.

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.