News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Lazy Admin Menu

Started by dougiefresh, July 21, 2014, 09:15:48 AM

Previous topic - Next topic

Steve

#140
Quote from: dougiefresh on October 05, 2014, 08:09:25 PM@Steve: Can you uninstall DevCenter, then reinstall it?  The hooks might be screwed up.....

With which version? 1.9?

Edit: I tried what you asked and it does put the number of errors on the admin button but anything I do generates more errors. If I go into a board, two more errors, etc.
My pet rock is not feeling well. I think it's stoned.

Steve

Edit 2: I uninstalled devcenter and LAM.

I reinstalled devcenter and THEN LAM and everything works perfectly!!

The admin button shows the number of errors and none are generated by normal actions around the board. WOOT! :D
My pet rock is not feeling well. I think it's stoned.

dougiefresh

Quote from: Arantor on October 05, 2014, 08:36:42 PM
You could just look at the end of the string to see if substr($title, -1) == ']' ;) (or whatever variable you're using) and if it is already there, assume it's been done.
That's fine and dandy IF the DevCenter hook is executed before the Lazy Admin Menu hook.  But what if it's the other way around?  The DevCenter mod blindly appends the error count to the Admin title.... and there lies the problem.

The other problem with this is that use the hook handler as a normal function call in Subs.php results in errors while uninstalling, completely breaking the forum software....  OBVIOUSLY not a good thing....

EDIT: I could check to make sure the file exists before requiring it.....

Quote from: Steve on October 05, 2014, 09:09:49 PM
I uninstalled devcenter and LAM. 

I reinstalled devcenter and THEN LAM and everything works perfectly!!

The admin button shows the number of errors and none are generated by normal actions around the board. WOOT! :D
Awesome!

Arantor

You could even do a function_exists() check before calling it ;)
Holder of controversial views, all of which my own.


dougiefresh

Quote from: Arantor on October 06, 2014, 08:01:05 AM
You could even do a function_exists() check before calling it ;)
Well, if the file exists, then the function definitely exists....  Seems to be overkill to check both (at least to me, it does)

Arantor

Then just check the function exists ;) I've always found it safer to rely on functional existence rather than file existence due to edge cases around mod installations and hooks.
Holder of controversial views, all of which my own.


NekoJonez

I think I caught another bug D:

As soon as I installed v1.9 a lot of errors dumped of Simple Portal... They came from the shoutbox o.O?
Retro video game blogger, writer, actor, podcaster and general amazing dude.

Twitter
My Blog

dougiefresh



LOL!  Now that I got that outta my system, lemme look into it....

dougiefresh

Uploaded v1.11 - October 6th, 2014
o Added some code to Subs.php to prevent screwing up forum during uninstallation of mod.
o Upgrade possible from v1.10 to v1.11 since uninstalling mod screws up the forum.
o Added code for 2-second cache to the admin area to prevent double code execution...




@NekoJones: Thank you for reporting that this mod generates some errors.  I think I took care of those errors, however, since you didn't show which errors you had, I can't be 100% sure....

@Steve: Thank you for reporting the problem you've had.  I've gotten this mod to work as a post-integration function, so that the user-experience is what is expected....

NekoJonez

#149
Does v1.11 also update the arcade thingy? (Dumb question perhaps since it was in the 1.10 patch)

It works.

But the 2nd admin... Well, the errors of Simple Portal are back :/

http://www.arpegi.be/index.php?action=portal;sa=shoutbox;shoutbox_id=1;time=1412704457;xml
8: Undefined index: sp-positionTop
File: /****/Sources/Admin.php


That and it has the error for  sp_admin_shoutbox_add, sp_admin_shoutbox_list, sp_admin_shoutbox_title... In total 25 errors.




I was also ... affected by this: http://www.simplemachines.org/community/index.php?topic=528577.0

I fixed it and maybe that caused the errors. I'll keep you up to date if the errors show up again. But if I'm totally derping here... (When it has nothing to do with the errors I mentioned earlier) ignore this edit plz.
Retro video game blogger, writer, actor, podcaster and general amazing dude.

Twitter
My Blog

dougiefresh

Quote from: NekoJonez on October 07, 2014, 02:45:12 PM
Does v1.11 also update the arcade thingy? (Dumb question perhaps since it was in the 1.10 patch)
:o Not a dumb question, as I forgot about that bug report....  :-[  I'm pretty sure that neither v1.10 or v1.11 resolves the Arcade issue.....

NekoJonez

Hey dude, the arcade thingy is working :)

Well, the life of a coder never stops eh? Don't worry, I know the feel. I'm working at a reception.
Retro video game blogger, writer, actor, podcaster and general amazing dude.

Twitter
My Blog

dougiefresh

Does the arcade thingy produce errors?

NekoJonez

Nope, the errors that are in the log start all with sp_* and come from that (kind) of url mentioned in one of prev posts.

I bet it's SimplePortal being a b-cth to this mod.
Retro video game blogger, writer, actor, podcaster and general amazing dude.

Twitter
My Blog

dougiefresh

Well, I can imagine that there are other mods that will need "assistance" to work properly with this mods....  I so look forward to the bug reports  ::)

Ninja ZX-10RR

Howdy, I missed the last 4 pages or so XD so are you done with that crap? :P
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

dougiefresh

Done with what crap?  Simple Portal?  If so, I hope so....

Ninja ZX-10RR

Yeah don't misunderstand me, with that I meant bugs (hate them pretty much), SP and weird compatibility problems :) I will update when I have some time.
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

dougiefresh

Quote from: ♦ Ninja ZX-10RR ♦ on October 11, 2014, 07:11:13 AM
Yeah don't misunderstand me, with that I meant bugs (hate them pretty much), SP and weird compatibility problems :) I will update when I have some time.
Ah!  Well, I hope I'm done with all that stuff.....  But I'll fix bugs as they are reported.

Ninja ZX-10RR

* ♦ Ninja ZX-10RR ♦  likes the message above :)
Quote from: BeastMode topic=525177.msg3720020#msg3720020
It's so powerful that on this post and even in the two PMs you sent me,you still answered my question very quickly and you're apologizing for the delay. You're the #1 support I've probably ever encountered man, so much respect for that. Thank you, and get better soon.

I'll keep this in my siggy for a while just to remind me that someone appreciated what I did while others didn't.

♥ Jess ♥

STOP EDITING MY PROFILE

Advertisement: