1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Somebody finish this. All that is needed is the ACP

Discussion in 'Off Topic' started by harmor, Jun 27, 2011.

  1. harmor

    harmor New Member

    I pirated Xenforo to play with the code and I don't have the motivation nor time anymore. Someone can have this code and do what you please. It's a way to add links to the navigation bar without creating a PHP script.

    I know it's a simple code but I didn't want it to go to waste.


    class NavBarManager_ControllerPublic_Index extends XenForo_ControllerPublic_Abstract
        public static function 
    addNavbarTab(array &$extraTabs$selectedTabId)

    $visitor XenForo_Visitor::getInstance();
    $db XenForo_Application::get('db');

    $navlink_query $db->fetchAll('SELECT nav_id, title, href, position, usergroup_perms, linkstemplate FROM navbar_manager');
    $navlink_query AS $rowName => $navlink)
    $usergroupPerms explode(","$navlink['usergroup_perms']);
    in_array($visitor['user_group_id'], $usergroupPerms) OR $navlink['usergroup_perms'] == '0')
    $extraTabs['info'.$navlink['nav_id']] = array(
    'title' => $navlink['title'],
    'href'  => XenForo_Link::buildPublicLink('full:'.$navlink['href']),
    'selected' => ($selectedTabId == $navlink['href']),
    'linksTemplate' => (!empty($navlink['linkstemplate'])) ? $navlink['linkstemplate'] : '',
    'position'  =>  $navlink['position']);
    Install/Uninstall Code

    class NavbarManager_Alterdb
        public static function 
    $db XenForo_Application::get('db'); 
    $db->query('CREATE TABLE IF NOT EXISTS `navbar_manager` (
                  `nav_id` int(10) NOT NULL AUTO_INCREMENT,
                  `title` varchar(60) NOT NULL,
                  `href` varchar(100) NOT NULL,
                `postion` varvhar(40) NOT NULL,
                `usergroup_perms` varchar(40) NOT NULL,
                `linkstemplate` varchar(70) NOT NULL,
                  PRIMARY KEY (`nav_id`)
        public static function 
    uninstallCode(array $addonInfo)
    $db XenForo_Application::get('db'); 
    $db->query('DROP TABLE navbar_manager');
  2. Onimua

    Onimua Well-Known Member

    How thoughtful. :rolleyes:
    Blandt likes this.
  3. Peggy

    Peggy Well-Known Member

    You... Pirated a copy? How nice of you to mention it.

    (note the sarcasm)
  4. Russ

    Russ Well-Known Member

    If you had an active license you'd realize this mod already exists lol :rolleyes:
    Peggy likes this.
  5. yavuz

    yavuz Well-Known Member

  6. Shamil

    Shamil Well-Known Member

    I don't know what to say. I don't know if this is a good thing or a bag thing.
  7. jonsidneyb

    jonsidneyb Well-Known Member

    Pirated? Not good.
  8. Shamufish

    Shamufish Member

  9. jonsidneyb

    jonsidneyb Well-Known Member

    Post reported to see what they think.
  10. José Guedes

    José Guedes Active Member

  11. Slavik

    Slavik XenForo Moderator Staff Member

    I like his honesty.

    But lets burn him anyways.
    John and Steve F like this.
  12. jonsidneyb

    jonsidneyb Well-Known Member

    but pirating is not honest.
  13. Shamil

    Shamil Well-Known Member

    He didn't have to say he pirated it, and risk getting burned.
  14. grant sarver

    grant sarver Well-Known Member

    I'm a little conflicted, gimme some perspective. As a server-side script, does it really matter? Seems to me it would only be a problem (sin, crime?) if you "go live". Anyone can get the codebase for VB or XF or many others. Is there anything wrong with looking at the code, and maybe playing with it? No harm, no foul, right?

    Like to hear Kier's opinion on this. I think there's a little hacker inside of every coder.
    dutchbb, iTuN3r and Alice Clark like this.
  15. grant sarver

    grant sarver Well-Known Member

    Mortal or Venial?
  16. jonsidneyb

    jonsidneyb Well-Known Member

    I give you a like thinking you where of high morals standards then you turn around and message spam me.
  17. Saeed

    Saeed Well-Known Member

    *scratching head* :confused:
  18. jonsidneyb

    jonsidneyb Well-Known Member

    It was a spam message via xenforo's message system. She was promoting mailing lists to buy.
  19. Saeed

    Saeed Well-Known Member

    And I hope was executed with XF's powerful terminator? :)
  20. jonsidneyb

    jonsidneyb Well-Known Member

    Hmmm, she seems to have vanished from existance.

Share This Page