WordPress.org

Ready to get started?Download WordPress

Forums

Contextual Related Posts
Contextual related posts based on a custom field instead of title (22 posts)

  1. marcie73
    Member
    Posted 2 years ago #

    Hello to everyone,
    I just trying to do something that is out of my knowledge and maybe is not even possible to do it!
    For what I'm doing I need to display posts that won't match either title or content, so I had the idea to insert a custom field but then I guess I should change the php fucntions in the plugin main file. I suppose I need to change post_title with my new field name...but I think it's not enough, surely I would mess up everything. The problem is that I don't know php, just trying to learn the basics very slowly, anyone can give a little help? thanks and apologize for my incompetence...

    http://wordpress.org/extend/plugins/contextual-related-posts/

  2. Ajay
    Member
    Plugin Author

    Posted 2 years ago #

    Marcie, I'm not sure this is the plugin that will perform the feature you are looking from.

    What I can see, you want a plugin that lists posts that have a custom field?

  3. marcie73
    Member
    Posted 2 years ago #

    Hi Ajay, thank you for your reply!! I wasn't hoping anymore....
    I briefly explain you what I want to do: i need to build a portfolio of design works, divided by category (graphics, web, photography, movies.. etc..). All these works are made for different clients and each client may have works from different categories. When opening a work (a post) I need that related posts to that client would show. So I don't want to use title otherwise I'm forced to insert in each post title the name of the client. Or either content, because other uneccesary words would be picked up, as for instance the name of the type of work itself that is also related to other clients. So the idea is to insert a custom field who I would put the name of the client only, the only keyword used for my filering. I have already styled this plugin, would be a pity not to use it, but if there's not choice I would be happy to find something else as long as the will be the feature to use the featured image beside the post title. Hope I've been clear describing my problem.
    Thank you if you can help!

  4. Ajay
    Member
    Plugin Author

    Posted 2 years ago #

    I think I've understood the problem. Unfortunately, this plugin won't satisfy the requirement.

    However, do check out http://wordpress.org/extend/plugins/get-custom-field-values/ which might suit your requirement.

    Also, maybe http://justintadlock.com/archives/2007/11/01/wordpress-custom-fields-listing-a-series-of-posts if you want to do this manually

  5. marcie73
    Member
    Posted 2 years ago #

    Thank you Ajay, I've been trying looking through your links but not luck in finding something suitable. I have found this instead:
    http://www.emanueleferonato.com/2010/05/29/how-to-list-all-wordpress-posts-with-the-same-custom-field-value/
    It lists posts by custom field value so it does what I need, but now I don't know how to insert my post-thumbnail. I already put my help request, hope somebody wiil give me a help. Any suggestion on that?
    Thank you again. Marzia

  6. Ajay
    Member
    Plugin Author

    Posted 2 years ago #

    Marcie, you will need to try and duplicate the code in the ald_crp function in the main plugin file

  7. marcie73
    Member
    Posted 2 years ago #

    Sorry, but I didn't get it. The contextual related plugin (crp) has already the feature of having the post thumbnail, the problem was I can only filtering using the post-title or the content and not a custom field as I need. That's why I went looking for something else. Sorry I didn't understand but it's probably due to my incompetence about programming...Can you explain a little better to this stubborn person (me)? Thank you Ajay.

  8. Ajay
    Member
    Plugin Author

    Posted 2 years ago #

    Marcie, the CRP plugin already has the feature of post-thumbnails, but this for list that the plugin pulls out.

    From what I understood, you want to pull out the related posts from a custom field and add in the post thumbnail as well.

    If you'd like to see how I implemented this feature, you'll need to refer to the ald_crp function

  9. marcie73
    Member
    Posted 2 years ago #

    Ok Ajay, I'll try out...Thank you again!

  10. marcie73
    Member
    Posted 2 years ago #

    Hi Ajay, i'me here again, I tried to send a message from your blog but it fails in sending.
    Considering my knowledge it's pointless even trying to sort it myself. I already asked a programmer I know, but now he is too busy and my site start being really urgent. The best person would be you, but I don't know if you are willing or you a have time to do it, obviosly not for free, and I don't even imagine how much work is needed and how it would be in terms of price. If you want to get in contact with this is my email:
    marzia@ellittica.com Thank you!

  11. Ajay
    Member
    Plugin Author

    Posted 2 years ago #

    Marcie, unfortunately, this doesn't look very likely for me in the next few weeks. My day job doesn't give me breathing space.

    I'll try to take a look at this on the weekend if possible.

  12. marcie73
    Member
    Posted 2 years ago #

    Ajay, sorry for that, I imagine you are busy!! I would love to have time lo learn php but this is a crazy world we are in...thank you for trying, I'm very grateful to you. So i'll be waiting for your news during of after the weekend. Have a good day!

  13. marcie73
    Member
    Posted 1 year ago #

    Hi Ajay, you won't believe it but I'm still here stuck where I was 1 month ago. Hopefully the site stopped to be so urgent thanks to other urgents works that have been put ahead, but now they are asking me again if "that thing" has been fixed or not.
    Just wondering...are you still very busy? Do I have any hopes at all?... :-)
    Thank you!

  14. Ajay
    Member
    Plugin Author

    Posted 1 year ago #

    Marcie... let me try to see what I can do this weekend.

  15. marcie73
    Member
    Posted 1 year ago #

    Hi Ajay, just to notice you that I'm trying to sort it out using taxonomies and a piece of code that seems to work but need to be completed. I asked help to a new developer hoping he will be able to solve it. Thank you anyway.

  16. Ajay
    Member
    Plugin Author

    Posted 1 year ago #

    Marcie, thanks for the update. Do let me know if you succeed and would like me to share the code with other users.

    I've also been taking a look at this. however, it won't be in the current version for atleast another few versions, because it is a completely new set of code.

  17. Ajay
    Member
    Plugin Author

    Posted 1 year ago #

    http://wordpress.org/extend/plugins/wordpress-23-related-posts-plugin/ seems to achieve the related by tags, but I am not sure if it has thumbnail support

  18. marcie73
    Member
    Posted 1 year ago #

    Thank you Ajay, If I find the solution I will definitely share it.

  19. marcie73
    Member
    Posted 1 year ago #

    Hi Ajay,
    finally I sorted it (and with no external help!!). I managed to put together stuff around and it ended up to work!. It is probably not perfect and incomplete but as far I see it does what I want!
    My initial purpose (using a custom field) maybe was not the correct way, but since I'm a beginner I learn things every day. My need was not to show the field but it was actually to categorize my posts and then filtering them. I discovered taxonomies and realised they could better what I wanted.
    So, this thread should have another name now :-)....

    First of all I add my taxonomy "Clienti" in the file functions.php:

    [Code moderated as per the Forum Rules. The maximum number of lines of code that you can post in these forums is ten lines. Please use the pastebin]

    These are the references:
    http://wp.smashingmagazine.com/2012/01/04/create-custom-taxonomies-wordpress/
    http://www.ilovecolors.com.ar/display-related-posts-custom-taxonomies/
    http://stackoverflow.com/questions/8833420/wordpress-a-page-with-random-posts

    I'm so happy Ajay! Thanks for support!

  20. Ajay
    Member
    Plugin Author

    Posted 1 year ago #

    Marcie, this sounds good.

    The code got moderated out due to forum rules, could you please repost on pastebin above so I can take a look?

  21. marcie73
    Member
    Posted 1 year ago #

    Ajay, I'm not sure I used pastebin in the right way...try if you can see this url:
    http://pastebin.com/rxJzeY52

  22. Ajay
    Member
    Plugin Author

    Posted 1 year ago #

    Thank you. This is visible.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic