Announcement

Collapse
No announcement yet.

Select Statement For Mod Cp

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • James Hill
    replied
    I figured it out.

    It needed to be done with another while statement, although I am sure that there is an easier way to get it done this one worked.

    JH

    Leave a comment:


  • James Hill
    started a topic Select Statement For Mod Cp

    Select Statement For Mod Cp

    I am working on the ability for moderators to grant/revoke access to registered users to the forums they moderate. I have been able to imbed the code to allows the grant/revoke but am having problems on the forum select statement.

    This is the current code
    Code:
    $forumlist=$DB_site->query("SELECT * from forum ");
    What I want to do in the end is do a conditional select based on the results from a select from the moderator table.

    Example:
    Code:
    $forumlist=$DB_site->query("SELECT * from forum where forum.forumid = moderator.forumid and moderator.userid = $bbuserinfo[userid]");
    now I know that the follwing sniplet of code will fail (I have tried it :P ) But I am unsure on how to approach this without having to rewrite functional code.


    The code in reference is in the Edit Access part of user.php.

    James
widgetinstance 262 (Related Topics) skipped due to lack of content & hide_module_if_empty option.
Working...
X