• Is it possible to restrict a user to being able to post (write) to one category only?

    What I want to do is use WordPress as a news fed site for an online mall. Each user on the site is a store owner in the mall, and I wanted to make it so that when they log in and write a post, the post will be written to ‘their’ category.

    For instance, Mary owns ‘A Dolls World” which is a store in the mall. So I create a category called “A Dolls World”

    When Mary logs in and goes to write a post, the way it is now is that she can select which category she will post in. But as many new users are likely to do, she may forget to check ‘her’ category and post to the default category instead. I would like to make it so that she can only post in her own category.

    Is this possible?

    And, BTW, perhaps there’s a better way of doing this altogether. Allow me, if you will, to ask this:

    My idea is to create a category for each store in my mall and allow store owners to have their own news feed.

    My limited experience with WordPress allowed me only one idea on how to do this; by setting up a category for each store owner.

    This way, every time a store owner posts a news item, (and assuming the user put the item in their own category, the item would show up on the front page as well as in their category. Fans of that user could subscribe to that particular category, which would keep them updated on anything new in that users store.

    The news item would also show up on the front page, allowing fans of the entire mall to subscribe to the entire site rather than one or two individual stores.

    Is this one-category-per-store the best way to accomplish this, or am I missing some bigger picture.

    Thanks!

Viewing 15 replies - 16 through 30 (of 40 total)
  • oh yeahh, if this is of any help,

    php5
    mysql5
    apache 2.2
    FreeBSD 6.1

    i looked at the code allready, there are the same amount of {s as there are }s. NOthing else jumps at me EXCEPT for having a class definition in multiple <?php blocks. But php is not my game, so i dont know, ??

    Thanks again,

    As far as brackets go, that PHP looks good to me. manstraw, can you post your version of that plugin, the version you have working (I know they are the same version number, but perhaps something happened and you have a better version)? And if that code is copied and pasted into mozey’s site and there’s still a parse error, something else is going on.

    mozey, does your site work fine other than this issue?

    tsguitar, good thinking,

    and yes, everyhthing else is good!, to the best of what i can tell, One plugin i have gives me some warnings, but i cannot see how that would effect it.

    If there is an output that you would like to look at please let me know, thanks,

    ok, here yas go. https://mybeausejour.com/wordpress/wp-content/plugins/limitcats.php.txt

    I haven’t looked at yours to see if it’s different.

    Manstraw, i am taking a stab that you are running a different version of php than the one i’m running (5.1.4). And i think the one i’m running inforces the one <?php block per class rule, Keeping that in mind, i’m going to edit the code to suffice that. and i’ll keep you updated.

    Aright, so i fixed that!, and NOTHING!, anyone running php5 along with limitcats.php at all? or am i the only one?

    yeah, my php is probably around 4.3.2.

    I’m also interested in getting this sort of thing working. I would like to have any user be able to be restricted to posting in a certain category. Has anyone seen a plugin on this?

    have you read this whole thread? the limit categories plugin combined with the role manager plugin allow you infinite possibilities in controlling which categories users can post to.

    Yeah, but it’s definitely a kluge. I’m looking for something that would restrict access by user_id as compared to restricting access by user_role.

    why? what does user_id comparison offer that user_role comparison does’nt?

    wordpess multuser should be implemented like that tho. I”m downgrading to php4 for catlimits.php ?? it does the job.

    Well, Category Access restricts by user_id, but it also restricts reading (it’s main purpose). Perhaps you can bribe the author with a wild night at your place and all the kool-aid he can drink, and he’ll make you something that only restricts posting instead of reading. But I still think that doing it with roles is more powerful/flexible.

    OKAY, confirmed, catlimits.php (catagory limits) does not work on php5, i just downgraded to php4 and it works like charm. ?? i really want this plugin, and i do NOT want to program.

    have you contacted the author? perhaps he/she is interested it making it work with 5, or has some insight?

    I started a thread on thier site, and i got no response!
    https://redalt.com/support/topic/253
    He/she must have lots on thier table.

Viewing 15 replies - 16 through 30 (of 40 total)
  • The topic ‘Can you restrict users to write to only 1 category?’ is closed to new replies.