WordPress.org

Ready to get started?Download WordPress

Forums

AdRotate
[resolved] AdRotate menu disappears in the admin menu (13 posts)

  1. ww_hoax
    Member
    Posted 4 months ago #

    Good morning,
    Unfortunately AdRotate disappears in the admin area when I activate Simple Download Monitor (http://wordpress.org/plugins/simple-download-monitor/).
    If I simultaneously activate Simple Download Monitor and Slideshow (http://wordpress.org/plugins/slideshow-jquery-image-gallery/) AdRotate reappears.
    I have tested that on two different sites.
    However, it is not related to these two plugins, because on a third site I cannot reproduce it. Really amazing ...

    https://wordpress.org/plugins/adrotate/

  2. Arnan de Gans
    Member
    Plugin Author

    Posted 3 months ago #

  3. ww_hoax
    Member
    Posted 3 months ago #

    Sorry Arnan, I forgot to mention that the error occurred on the current version after the update.

    I have read you blogpost.

    Sorry I have forgotten to mention it.

  4. ww_hoax
    Member
    Posted 3 months ago #

    sorry - it is not resolved: I have testet it once again

    1. manually downgrade from 3.9.8 to 3.9.4 (everything works fine)
    2. automatic upgrade from 3.8.4 to 3.9.8 the admin entry "AdRotate" disappears if I install "Simple download Monitor"

    Please try the scenario

    Many thanks

  5. Arnan de Gans
    Member
    Plugin Author

    Posted 3 months ago #

    AdRotate follows the manual for adding menu's to the letter. The problem is likely with the Simple download monitor.
    Some plugins do not follow standards and just "hijack" the menu array, making a mess of things.

  6. @Armin,

    I am one of the core developers for Simple Download Monitor. I am a little concerned about this comment you made:

    Some plugins do not follow standards and just "hijack" the menu array, making a mess of things.

    I would suggest not jumping to such rash conclusions in the future. While I agree there are some plugins which, unfortunately, "make a mess of things"... you almost make it sound as if you are insinuating "Simple Download Monitor" follows these sloppy practices; which it most certainly does not.

    Did you take the time to install both plugins and troubleshoot? I did. I cannot replicate the issue. I have both plugins installed on my test site.. and both menu items appear properly.

    That is the extent of my testing. I have no other plugins installed.

    However...

    Judging from your comment (the second post to this topic); it appears you have had some trouble with the menu item disappearing in the past.

    Perhaps it would be better for you to find the specific cause, rather than hap-hazardly 'blaming' other plugins.

    I haven't dug too far into your code; but I would imagine the issue has something to do with this:

    add_object_page('AdRotate', 'AdRotate', 'adrotate_ad_manage', 'adrotate', 'adrotate_info');

    From the codex:

    This essentially does the exact same thing as add_menu_page(), but checks (and increments) the $_wp_last_object_menu global variable to add the menu item to the last position in the menu items. So, if $_wp_last_object_menu has already been incremented to 25, this call to add_object_page() will send 26 in the $position argument to the add_menu_page() function.

    This from WP Trac:
    https://core.trac.wordpress.org/ticket/21445

    An excerpt from the link above:

    When the action admin_menu is fired, I have seen add_object_page() overwrite the last custom post type menu item. $_wp_last_object_menu is supposed to control this, but in this case, it failed.

    From all the people who experience an issue with the admin menu items; how many of them are affecting custom post types? All of them??

    If I were you... I'd test this further.

    Hope this information is of some help.

    I apologize if I come off as too assertive or offensive.. but again, be careful of what you say ;)

    PS: See the last comment by Sergey on this Trac ticket:
    https://core.trac.wordpress.org/ticket/21445

    PSS: WOW - I just read your remarks here:
    http://www.adrotateplugin.com/2014/03/missing-menu-items-for-a-bunch-of-sites/

    This is what you are telling your PREMIUM customers? Totally not cool :(

  7. ww_hoax
    Member
    Posted 3 months ago #

    Many thanks Josh!

    I have changed line 94 in adrotate.php from

    add_object_page('AdRotate', 'AdRotate', 'adrotate_ad_manage', 'adrotate', 'adrotate_info');

    into

    add_menu_page('AdRotate', 'AdRotate', 'adrotate_ad_manage', 'adrotate', 'adrotate_info');

    This fix my issue.
    Many thanks.

  8. Arnan de Gans
    Member
    Plugin Author

    Posted 3 months ago #

    I'll look into changing the menu function.

    Josh, no need to feel attacked and take a jab like that.
    9 out of 10 times it IS the other plugin making a mess of things - So yes, that is my logical assumption by now.

  9. Arnan... I did feel attacked.. and rightfully so. You told your user it was my plugin causing the issue. However, you handled it like a champ!

    Just remember.. there are still solid WP developers out here... don't feel alone. And certainly don't assume ;)

    9 out of 10 times it IS the other plugin making a mess of things - So yes, that is my logical assumption by now.

    Perhaps... even, probably so. But, that still doesn't exclude you somehow from taking the time to look into the issue. I mean, I spent all of 10 minutes posting my comment above (including all references). Then.. you can point them to the issue (much as I did here) which 'gently pushes' them in the correct direction.. while still maintaining integrity with your premium products.

    You obviously have a nice product with a good level of demand. My 'jab' came from how I would have felt had I purchased your product; then read that blog post. How you decide to handle your customers from here is entirely up to you; not my business...

    We are on the verge of getting off topic here and might get closed ;)

    If I may ever offer my advice or suggestions.. you know how to find me :)

  10. Arnan de Gans
    Member
    Plugin Author

    Posted 3 months ago #

    Indeed, let's not get off topic.

    I'll close with this though -
    I'm literally busy with support/email/sales/administration 8-12 hours a day, 6 days a week. If I'm lucky I can work on my products and services for a few hours per week.

    This makes quick assessments such as; "AdRotate goes by the book so it's probably not a bug on my end" more acceptable. Luckily most of the time I'm right/accurate...

    This is not my lame excuse, this is just how things are.

    --

    ww_hoax, have you had any issues with the menus since you made that change?

  11. I'm literally busy with support/email/sales/administration 8-12 hours a day, 6 days a week. If I'm lucky I can work on my products and services for a few hours per week.

    Ohhhhh, don't I know it, brother :)
    We just need 10 days in a week, and 60 hours in each day... then we would be able to get everything done ;)

    It is amazing... and I have to agree with you 100%. I too, find myself consumed with support... while leaving very little time to develop. I imagine you're a "one-man team", much like myself. It makes it VERY difficult to stay focused and remain in high spirits. It's STRESS.. plain and simple!

    But again, you've handled this very well. Thank you for responding, and keeping a clear and calm head.

  12. ww_hoax
    Member
    Posted 3 months ago #

    Dear Arnan, no issue since the change. Everything works.
    Nice weekend!

  13. Arnan de Gans
    Member
    Plugin Author

    Posted 3 months ago #

    Right :) I'll see if I can use that then, instead of the object.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.