Title: Two buttons loading
Last modified: May 26, 2022

---

# Two buttons loading

 *  [kartdigital](https://wordpress.org/support/users/kartdigital/)
 * (@kartdigital)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/)
 * Hi,
 * We are using the LearnDash Visibility Control plugin to display buttons in the
   menu based on what course a user is enrolled in.
 * At the moment, we have two courses, so we have two buttons. However, both buttons
   are appearing while the header is loading.
 * Aside from optimising the website speed (we have done this), do you have any 
   suggestions for how we can prevent this flicker?
 * Thanks!
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ftwo-buttons-loading%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

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

 *  [Saurabh Chauhan](https://wordpress.org/support/users/saurabhpro/)
 * (@saurabhpro)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15680097)
 * Hi there,
 * You’re using these two classes in two menu elements:
 * 1. visible_to_group_2982
    2. visible_to_group_4539
 * As I’m logged-out and visiting the link you provided, the buttons are hidden.
   So, I think the functionality is working.
 * You said, “two courses” but you’re using “visible_to_group_123” instead of “visible_to_course”.
 * Also, please test with an actual user that is enrolled in a specific course/group.
   It seems you’re trying from an admin account. Please test again and let me know.
 * Saurabh
 *  Thread Starter [kartdigital](https://wordpress.org/support/users/kartdigital/)
 * (@kartdigital)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15680170)
 * Hi Saurabh,
 * Thanks for your prompt response.
 * That’s right, the buttons are only visible when a user is logged in so that is
   when the issue occurs.
 * You can check using the test user login details below.
    username: charlie.nicholls-
   5212 password: xO%*YFaiT*dsl%D^E782p8qE
 * Thanks,
    Charlie
 *  [Saurabh Chauhan](https://wordpress.org/support/users/saurabhpro/)
 * (@saurabhpro)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15680271)
 * It is happening because the script we add in “head” tag is executing late, we
   tried it in our setup and it works fine.
 * As you said “optimize”, I’m suspecting a plugin you’re using could cause the 
   issue.
 * Saurabh
 *  Thread Starter [kartdigital](https://wordpress.org/support/users/kartdigital/)
 * (@kartdigital)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15684075)
 * Hi Saurabh,
 * Thank you for your response.
 * Would it be possible to engage you to take a deeper look and identify what plugin
   is conflicting and causing this?
 * Thanks
    Charlie
 *  [Saurabh Chauhan](https://wordpress.org/support/users/saurabhpro/)
 * (@saurabhpro)
 * [4 years ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15688202)
 * Hi Charlie,
 * All I can suggest is you should try to deactivate any plugin that is related 
   to page speed optimization and now try to test the button visibility.
 * If that doesn’t work, then try to deactivate all other plugins except Visibility
   Control for LearnDash and LearnDash LMS and test if in this case, it works fine?
 * If yes? then try to activate other recently active plugins one at a time and 
   try to test the button visibility to check which plugin is causing the issue.
 * Saurabh
 *  Thread Starter [kartdigital](https://wordpress.org/support/users/kartdigital/)
 * (@kartdigital)
 * [3 years, 12 months ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15690457)
 * Hi Saurabh,
 * Thank you for your valuable guidance.
 * We will try your suggestions and reach out if we have further questions.
 * Many thanks,
    Charlie

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

The topic ‘Two buttons loading’ is closed to new replies.

 * ![](https://ps.w.org/visibility-control-for-learndash/assets/icon-256x256.png?
   rev=2146785)
 * [Visibility Control for LearnDash](https://wordpress.org/plugins/visibility-control-for-learndash/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/visibility-control-for-learndash/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/visibility-control-for-learndash/)
 * [Active Topics](https://wordpress.org/support/plugin/visibility-control-for-learndash/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/visibility-control-for-learndash/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/visibility-control-for-learndash/reviews/)

## Tags

 * [grassblade](https://wordpress.org/support/topic-tag/grassblade/)

 * 6 replies
 * 2 participants
 * Last reply from: [kartdigital](https://wordpress.org/support/users/kartdigital/)
 * Last activity: [3 years, 12 months ago](https://wordpress.org/support/topic/two-buttons-loading/#post-15690457)
 * Status: not resolved