Display blog posts in user profile
Permalink Browser Info Environment
I'm using problog for one of my clients site. There is a need to display blogs for problog author in their profile page. How could I do that?
Note: I'm not using user blog.
Note: I'm not using user blog.
Type: | Discussion |
---|---|
Status: | New |
Yes the $profile only work properly only when you logged in with username.
I wonder if there is a way to make a custom template using the blog search or the blog list that gets the user ID from the URL and filter the list based on that user ID?
Here is what I'm working with so far that may help sort this out. I haven't figured it out yet, but I feel like I'm pretty close.
I have a user attribute called "Business Name". The business names are also the names of my blog categories.
I have a user attribute called "Business Name". The business names are also the names of my blog categories.
<?php defined('C5_EXECUTE') or die(_("Access Denied.")); extract($blog_settings); global $c; $u = new User(); <!-- Get the user info --> $memberBusinessName = $c->getAttribute('business_name'); <!-- Get the user attribute to match to the category name --> if (count($cArray) > 0 && in_array($u->getUserID(),$memberBusinessName == $cat)) { ?> <!-- Display page list code here -->
I'm creating categories that correspond to the username. I may ossibly use something like the code below to add a blog list and filter by that category:
I'm unsure yet if I have to be logged in as that user to have it display the correct information.