Title: Problems with W3 validation for XHTML
Last modified: August 30, 2016

---

# Problems with W3 validation for XHTML

 *  Resolved [Stevennn](https://wordpress.org/support/users/stevennn/)
 * (@stevennn)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/problems-with-w3-validation-for-xhtml/)
 * Hello,
 * can you please help me with clearing errors for W3 validation.
 * After putting your code:
 * function pb_the_content_shortcode_fix($content) {
    $array = array( ‘<p>[‘ => ‘[‘,‘]
   </p>’ => ‘]’, ‘]‘ => ‘]’, ‘]‘ => ‘]’ );
 *  return strtr($content, $array);
    } add_filter(‘the_content’, ‘pb_the_content_shortcode_fix’);
 * I still have these errors:
 * there is no attribute “role” on
    …arter ezcol-last”><div id=”accordion-1″ class
   =”accordion no-js” role=”tablist”>
 * there is no attribute “aria-controls”
    …rdion-title” role=”tab” aria-controls
   =”accordion-1-c1″ aria-selected=”false”
 * there is no attribute “aria-selected”
    …ntrols=”accordion-1-c1″ aria-selected
   =”false” aria-expanded=”false”>
 * and so on.
 * Thank you in advance.
 * [https://wordpress.org/plugins/accordion-shortcodes/](https://wordpress.org/plugins/accordion-shortcodes/)

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

 *  Thread Starter [Stevennn](https://wordpress.org/support/users/stevennn/)
 * (@stevennn)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/problems-with-w3-validation-for-xhtml/#post-6311063)
 * Changeing to <!doctype html> resolved most of error but there is still
 * Duplicate ID accordion-3
 * on link: [http://organicos-centarprirodnogzdravlja.hr/web-shop/](http://organicos-centarprirodnogzdravlja.hr/web-shop/)
   on [https://validator.w3.org/](https://validator.w3.org/).
 * Is that possible to fix?
 *  Plugin Author [philbuchanan](https://wordpress.org/support/users/philbuchanan/)
 * (@philbuchanan)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/problems-with-w3-validation-for-xhtml/#post-6311151)
 * Can you post the shortcode you are using for each accordion group? It looks like
   you may just be using some duplicate HTML in addition to the accordion shortcodes.
 *  Thread Starter [Stevennn](https://wordpress.org/support/users/stevennn/)
 * (@stevennn)
 * [10 years, 11 months ago](https://wordpress.org/support/topic/problems-with-w3-validation-for-xhtml/#post-6311164)
 * Found problem, someone deleted backslash for closing accordian. Thank you.

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

The topic ‘Problems with W3 validation for XHTML’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/accordion-shortcodes.svg)
 * [Accordion Shortcodes](https://wordpress.org/plugins/accordion-shortcodes/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/accordion-shortcodes/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/accordion-shortcodes/)
 * [Active Topics](https://wordpress.org/support/plugin/accordion-shortcodes/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/accordion-shortcodes/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/accordion-shortcodes/reviews/)

 * 3 replies
 * 2 participants
 * Last reply from: [Stevennn](https://wordpress.org/support/users/stevennn/)
 * Last activity: [10 years, 11 months ago](https://wordpress.org/support/topic/problems-with-w3-validation-for-xhtml/#post-6311164)
 * Status: resolved