• Resolved ldeschenes

    (@ldeschenes)


    Hi,

    When we edit a post, the window for adding an image has 3 tabs on top. The third one being “Optimole”. Is there a way to remove that third tab in order to force my users to use the media library itself ?

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Support Kush

    (@kushnamdev)

    Hi @ldeschenes,

    Thank you for contacting us.

    You can use this small snippet to hide this – https://gist.github.com/kushh23/411322dd3c801d1ab33d3b2bc6fce9f2

    Either use the code or download the zip to install as a plugin.

    Let me know if there is anything else we can help with.

    Best regards

    Thread Starter ldeschenes

    (@ldeschenes)

    Hi Kush,

    In fact, I want to hide it from everyone.

    Can I just add a line to “Simple CSS” ? What would be the CCS code ?

    I tried button#menu-item-optimole.media-menu-item { display: none !important; } to no success.

    Plugin Support Kush

    (@kushnamdev)

    Hi @ldeschenes,

    Adding css directly wont work, if you want to hide it from everyone you can just disable the unified image access feature and it will no longer be visible to anyone. But if you want to keep feature enabled and hide it on image modal only then try this code, it will hide for all users including administrators, add this to your theme’s functions.php file-


    add_action('admin_head', function () {
    $current_user = wp_get_current_user();

    echo '<style>button#menu-item-optimole { display: none !important; }</style>';

    });

    I hope this helps, thank you!

    Thread Starter ldeschenes

    (@ldeschenes)

    Hi Kush,

    Thanks for helping me!

    Unfortunutely, adding the last code as a code snippet did not worked.

    BTW, that CSS seems to target a button with ID menu-item-optimole, which would be more like an admin menu item, not a the media window tab.

    Plugin Support Kush

    (@kushnamdev)

    it works at my end, where did you added the snippet, please share a screenshot?

    Thread Starter ldeschenes

    (@ldeschenes)

    I added it with “Code Snippets” plugin like I do with many others PHP code.

    What screen do you want me to share ? Snippet adding or Add a Media ? And how do you want me to share it?

    Plugin Support Kush

    (@kushnamdev)

    It would be helpful if you can send for both. You can use the service like https://prnt.sc/ to share the screenshot,

    Thread Starter ldeschenes

    (@ldeschenes)

    Hi Kush,

    I did some more testing and fix it.

    Your code worked fine in the admin area… but what I wanted is to remove the tab when using the plugin “Frontier Post” for editing by super-user in front-end.

    The following code works fine for front-end :

    add_action('wp_head', function () {
    echo '';
    });

    Thanks again for your help!

    Thread Starter ldeschenes

    (@ldeschenes)

    Hi again Kusk,

    Last time you help me it was about the upgrade https://ww.wp.xz.cn/support/topic/site-layout-broken-after-upgrade/. It was really appreciated.

    I try to help another user that had the same problem and the moderator did not like it and deleted my message. He also did not like my reply (maybe my english was to rought… my language is french) and put me in moderation mode. You can see it here: https://ww.wp.xz.cn/support/topic/update-to-4-0-0-broke-site-layout/

    Anyway to remove this moderation stuff?

    Plugin Support Kush

    (@kushnamdev)

    Hi @ldeschenes,

    Glad to know that the issue is resolved. Regarding the moderation, unfortunately we cant do anything from our end but you can reach out to moderators and ask them about this, maybe they can assist you better.

    You can check the guidelines here – https://ww.wp.xz.cn/support/guidelines/#contacting-the-moderators

    Best regards

    Moderator Support Moderator

    (@moderator)

    For forum moderation issues, feel free to email forum-moderation[at]wordpress.og and that conversation can happen there in email.

    A forum topic is not an appropriate place for a moderation conversation.

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Inserting Image to page’ is closed to new replies.