WordPress.org

Ready to get started?Download WordPress

Forums

Business Directory Plugin
[resolved] Adding "Featured" Listings to Home Page Template (10 posts)

  1. justin.r.rosenthal
    Member
    Posted 1 year ago #

    Hello,

    I'd like to add a listing of our 3 latest "featured" listings to the home page template, here:
    http://bit.ly/WfMzIe

    You'll see the PHP error part way down the page.

    Help much appreciated!

    http://wordpress.org/extend/plugins/business-directory-plugin/

  2. businessdirectoryplugin
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Justin,

    Have you tried using the code from the Featured listing widget?

    I clicked the link you provided, but saw no PHP errors on the page. Did you already fix this? Looks like it's a flash site, so I'm not sure where the PHP is involved anyhow.

  3. justin.r.rosenthal
    Member
    Posted 1 year ago #

    Woops, here's the right shortlink: http://bit.ly/138OvGM

  4. justin.r.rosenthal
    Member
    Posted 1 year ago #

    Hey there, thanks for the great help. Added new sidebar and pulled in the featured listings widget.

    I see that the widget just displays the listing title. I'd like to pull in the excerpt, as on this page: http://bit.ly/116EEkB

    I'm trying to add this to the "Featured Practitioners" section on the home page.

    Code to add to the widget to present the listing excerpt?

    Thanks!

  5. businessdirectoryplugin
    Member
    Plugin Author

    Posted 1 year ago #

    Love your site, BTW. Nicely done. Would you like to be in the showcase? (http://businessdirectoryplugin.com/showcase/)

    I'll have to ask my developer and he's on a brief break, so let me get back to you on that.

  6. justin.r.rosenthal
    Member
    Posted 1 year ago #

    Thanks a lot!

    Yeah, we'll let you know once it goes live.

    Any ideas on getting that code? Super excited to get the BD featured listing excerpts on that front page.

    Thanks!

  7. businessdirectoryplugin
    Member
    Plugin Author

    Posted 1 year ago #

    He's not back yet. I will post it when it's available.

  8. businessdirectoryplugin
    Member
    Plugin Author

    Posted 1 year ago #

    My developer responded:

    This user is looking for is:

    echo wpbdp_render_listing($listing, 'excerpt');

    where $listing is the post object that represents the listing being shown. The $listing variable can be omitted but in that case the global $post variable should be set to a WPBDP listing or the function will return an empty string. The function is defined in api/api.php.

  9. justin.r.rosenthal
    Member
    Posted 1 year ago #

    Howdy,

    I know I'm asking a lot but I honestly don't know what to do this with this code... think you could post changes to the widgets.php and functions.php files that I could use to get the latest 3 featured listing excerpts?

    Hopefully this code would be useful for future development and other users of the plugin.

    Many thanks!

  10. businessdirectoryplugin
    Member
    Plugin Author

    Posted 1 year ago #

    Hi Justin,

    If you need assistance with PHP code, may I suggest looking on oDesk to hire a PHP developer that knows WordPress plugins? They will be a better resource to do that: http://odesk.com

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.