Title: [Plugin: WordPress Post Tabs] onclick Javascript instruction
Last modified: August 20, 2016

---

# [Plugin: WordPress Post Tabs] onclick Javascript instruction

 *  [byblos](https://wordpress.org/support/users/byblos-bib/)
 * (@byblos-bib)
 * [14 years, 3 months ago](https://wordpress.org/support/topic/plugin-wordpress-post-tabs-onclick-javascript-instruction/)
 * Post Tabs works really well on my WordPress 3.3.1 install. However, I want to
   use one tab to toggle the visibility of the comments on or off (so you basically
   end up with a tab “comments”, where you can see all the comments, and hide those
   comments when any other tab is activate). For that, I use the code of an old 
   plugin which is basically a javascript script: Hide or Show Comments: [http://wordpress.org/extend/plugins/hide-or-show-comments/](http://wordpress.org/extend/plugins/hide-or-show-comments/)
 * The most important instruction for that javascript function is (incorrect syntax):
 * onclick= togLayer(‘hide’/’show’);return false;
 * Does anyone know how I can link this instruction to the tabs in Post Tabs, so
   it is executed on every tab press (with one tab associated with the ‘show’ instruction,
   and all the rest with the ‘hide’ instruction)?
 * [http://wordpress.org/extend/plugins/wordpress-post-tabs/](http://wordpress.org/extend/plugins/wordpress-post-tabs/)

The topic ‘[Plugin: WordPress Post Tabs] onclick Javascript instruction’ is closed
to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/wordpress-post-tabs_ffffff.svg)
 * [WordPress Post Tabs](https://wordpress.org/plugins/wordpress-post-tabs/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wordpress-post-tabs/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wordpress-post-tabs/)
 * [Active Topics](https://wordpress.org/support/plugin/wordpress-post-tabs/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wordpress-post-tabs/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wordpress-post-tabs/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [byblos](https://wordpress.org/support/users/byblos-bib/)
 * Last activity: [14 years, 3 months ago](https://wordpress.org/support/topic/plugin-wordpress-post-tabs-onclick-javascript-instruction/)
 * Status: not resolved