Title: Accessibility error: empty buttons
Last modified: July 8, 2024

---

# Accessibility error: empty buttons

 *  [czinn](https://wordpress.org/support/users/czinnkzooedu/)
 * (@czinnkzooedu)
 * [1 year, 10 months ago](https://wordpress.org/support/topic/accessibility-error-empty-buttons/)
 * Three empty buttons are generated by the jquery even when there is only one media
   file (i.e. not a slideshow). This is an accessibility problem. Would it be possible
   to move the code that generates these buttons into the “if (total > 1)” conditional
   block so they are not added to the DOM if they are not needed? Or at least to
   give them a default value when they are added to the DOM?
 *     ```wp-block-code
       <button type="button" id="cboxPrevious"></button><button type="button" id="cboxNext"></button><button type="button" id="cboxSlideshow"></button>
       ```
   
 * Thank you!
    -  This topic was modified 1 year, 10 months ago by [czinn](https://wordpress.org/support/users/czinnkzooedu/).
      Reason: replaced broken image with code

The topic ‘Accessibility error: empty buttons’ is closed to new replies.

 * ![](https://ps.w.org/wp-colorbox/assets/icon-128x128.png?rev=2610062)
 * [WP Colorbox](https://wordpress.org/plugins/wp-colorbox/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-colorbox/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-colorbox/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-colorbox/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-colorbox/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-colorbox/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [czinn](https://wordpress.org/support/users/czinnkzooedu/)
 * Last activity: [1 year, 10 months ago](https://wordpress.org/support/topic/accessibility-error-empty-buttons/)
 * Status: not resolved