Facebook  Twitter 

SMFHacks.com

+-

SMFHacks.com

+- User Information

Welcome, Guest.
Please login or register.
 
 
 
Forgot your password?

+- Forum Stats

Members
Total Members: 4206
Latest: jagwire
New This Month: 0
New This Week: 0
New Today: 0
Stats
Total Posts: 42721
Total Topics: 7443
Most Online Today: 130
Most Online Ever: 2482
(April 09, 2011, 07:02:45 pm)
Users Online
Members: 0
Guests: 48
Total: 48

Author Topic: Admin Location  (Read 249 times)

0 Members and 1 Guest are viewing this topic.

Offline PapaFrizArcade

  • Awesome Post Ratings
  • Jr. Member
  • *****
  • Posts: 76
    • View Profile
Admin Location
« on: March 08, 2022, 08:42:43 am »
Hi,

I have your BADGES and AWESOME RATINGS mods (and your SIMPLE VIDEO EMBEDDER MOD).  All three create their own sections in ADMIN.  Is there any way to move them to either the MODIFICATIONS section,  or the POSTS section... or at least combine them to have a SMFHACKS section? 

Thanks!

Offline SMFHacks

  • Administrator
  • Hero Member
  • *****
  • Posts: 16205
    • View Profile
Re: Admin Location
« Reply #1 on: March 08, 2022, 01:15:24 pm »
In SMF 2.1 not easily. The mods are now written to use hooks instead of file edits in the admin menu areas.
Would require removing the hook menu code from each mod. Then replacing it with file edits. Admin.php

For instance for awesome post ratings in admin.php
Code: [Select]
'manageboards' => array(
'label' => $txt['admin_boards'],
'file' => 'ManageBoards.php',
'function' => 'ManageBoards',
'icon' => 'boards',
'permission' => array('manage_boards'),
'subsections' => array(
'main' => array($txt['boards_edit']),
'newcat' => array($txt['mboards_new_cat']),
'settings' => array($txt['settings'], 'admin_forum'),
),
),

Add after
Code: [Select]
'awesome' => array(
'label' => $txt['awepost_admin'],
'file' => 'AwesomePostRatings2.php',
'function' => 'AwesomeMain',
'custom_url' => $scripturl . '?action=admin;area=awesome;sa=adminset',
'icon' => (!function_exists("set_tld_regex") ? 'server.gif' : 'awesome.png'),
'subsections' => array(
    'adminset' => array($txt['awepost_txt_settings']),
'ratingtypes' => array($txt['awepost_ratingstypelist']),
),
),),
),

Then delete the code inside awesomepost_admin_areas in AwesomePostRatingsHook.php

The downside is that anytime the mod updates you have to redo the change. Or if you uninstall/reinstall the mod.


Get your Forum Ranked! at https://www.forumrankings.net - find out how your forum compares with others!

Like What I do? Support me at https://www.patreon.com/vbgamer45/
Like Like x 1 View List

Offline PapaFrizArcade

  • Awesome Post Ratings
  • Jr. Member
  • *****
  • Posts: 76
    • View Profile
Re: Admin Location
« Reply #2 on: March 08, 2022, 03:17:22 pm »
Seems like it's one of those "the amount of work necessary isn't worth the final result" kinds of things. 

Thank you...

 

+- Recent Topics

Feature to upload a photo straight when composing a message by SMFHacks
February 04, 2023, 08:13:46 am

Pretty URL's Pro rewriting URLs by [chrisB]
February 01, 2023, 05:18:47 pm

Question before purchase by SMFHacks
February 01, 2023, 03:53:33 pm

Unlimited ending time by Saftek
January 29, 2023, 10:06:26 pm

Converting from Aeva Media by ivanr
January 28, 2023, 10:09:42 am

[Mod] Post Scheduler by bayonetbrant
January 23, 2023, 02:24:09 pm

"Notify all store admins of item purchase" Not Working in SMF 2.1.2 or 2.1.3 by Michael Vail
January 22, 2023, 10:50:23 pm

[Request] Future consideration by [chrisB]
January 18, 2023, 08:42:53 am

Pretty Urls extras by SMFHacks
January 16, 2023, 04:00:57 pm

I don't think its installed correctly by SMFHacks
January 10, 2023, 05:56:21 pm

Powered by EzPortal