live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Show Hooks
« on January 11th, 2012, 09:20 AM »Last edited on January 12th, 2012, 08:17 AM by live627
I got this idea from http://custom.simplemachines.org/mods/index.php?mod=3285 (Integration Hooks Report, by Emanuel and Sinan).

This plugin is basically the same principle as the SMF mod linked above, but with some Wedge-y aspects (which, incidentally, are impossible in SMF, or, at least, extremely convoluted). It shows all hooks installed on the platform, categorised by plugin as can be  seen in the attachment. Yet, there will be some stray hooks where webmasters customise their forum,, if they didn't edit the core.

There is a drop down box which allows for filtering by a specific plugin, stray hooks, or none at all.

A confident man keeps quiet.whereas a frightened man keeps talking, hiding his fear.

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Show Hooks
« Reply #1, on January 11th, 2012, 11:38 AM »
Quite interesting!

TE

  • Posts: 286
Re: Show Hooks
« Reply #2, on January 11th, 2012, 11:45 AM »
Extremely useful for plugin developers, would be nice as a build-in feature  :cool:
Thorsten "TE" Eurich - Former SMF Developer & Converters Guru

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #3, on January 11th, 2012, 12:26 PM »
Oh, that's NICE. I deliberately didn't think about it being core, partly because I felt it could be done better as a plugin, partly because I suspect most users don't care and partly because I couldn't visualise a good UI. But I knew it could be done :)
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Show Hooks
« Reply #4, on January 11th, 2012, 01:37 PM »
I'd like to see that core too, yes.

Does it/would it provide the list of functions currently attached to any hooks...? As well as the ability to disable them?

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Re: Show Hooks
« Reply #5, on January 12th, 2012, 12:31 AM »
Quote
would be nice as a build-in feature
I'd tend to say otherwise. It would only be of REAL use to plugin developers. The average admin wouldn't even care, so long as what they use works. Since the latter is in the vast majority, I'd feel most woad see this as bloat.
Quote
disable them?
Only stray hooks can. I deliberately disabled the remove checkbox for plugin hooks on the assumption that either all or none can go.
Quote
Does it/would it provide the list of functions currently attached to any hooks...?
I like that idea and I know just how to implement it.
Quote
visualise a good UI.
Do you think the one I came up with is good?

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #6, on January 12th, 2012, 12:31 AM »
Yes, I think you came up with a good UI, though it's hard to tell exactly what the screenshot is showing since it got resized on upload :/

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Re: Show Hooks
« Reply #7, on January 12th, 2012, 12:47 AM »
I'll see if putting it in Aeva would help.
Posted: January 12th, 2012, 12:43 AM

Alright, I can't.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #8, on January 12th, 2012, 01:00 AM »
Try it now. I created a new profile in the permissions that should allow you to upload to it.

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Re: Show Hooks
« Reply #9, on January 12th, 2012, 01:11 AM »
It works, but The file size is larger (78049 KB) than the system allows. It's 162K.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #10, on January 12th, 2012, 01:16 AM »
Huh, try that now.

* Lurker idly speculates this will want some UI love going forward.

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Re: Show Hooks
« Reply #11, on January 12th, 2012, 01:32 AM »
It went through akright. Thanks for bothering to set it up for me.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #12, on January 12th, 2012, 01:36 AM »
No worries :)

FWIW, the album should be set up so that anyone in the Consultants group can post images to it. I might end up posting some of mine to it sometime as and when I get time :/

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
Re: Show Hooks
« Reply #13, on January 12th, 2012, 01:43 AM »
It uses the 'Consultants' profile. As to selecting which groups can write to it, I saw only 'Regular Members'.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Show Hooks
« Reply #14, on January 12th, 2012, 01:47 AM »
...ok, now I'm confused. I have no idea why that should be.

(Honestly, I get more than a shade confused by Aeva's permissions.)