I am using jQuery UI for information display on desktops in tabs and have so for some time. I have added Responsive Tabs to Accordion to show the same information in accordion tabs for tablets and smartphones as I am making the site responsive. The information is now shown in accordion format with all but first tab opened
, but the arrow keys don't trigger a display: block;
instead of display: none;
. Been at it for quite a while and am lost.
Here is the code loading the information in tabs and hopefully soon for tablet and smartphones in an accordion format:
<div class="demo tabs">
<div id="tabs11" class="tabsaccordion">
<ul class="resp-tabs-list">
<li id="tab-title-overview"><a target='_blank' href="#tabs-1">OVERVIEW</a></li>
<li id="tab-title-accomodation"><a target='_blank' href="#tabs-2">ACCOMODATION</a></li>
<li id="tab-title-facilities"><a target='_blank' href="#tabs-3"><?php if(in_category('liveaboards')) echo "SHIP FACILITIES"; else echo "RESORT FACILITIES";?></a></li>
<li id="tab-title-diving"><a target='_blank' href="#tabs-4">DIVING</a></li>
<li id="tab-title-surfing"><a target='_blank' href="#tabs-5">SURFING</a></li>
<li id="tab-title-activities"><a target='_blank' href="#tabs-6">ACTIVITIES</a></li>
<li id="tab-title-special"><a target='_blank' href="#tabs-7">SPECIAL</a></li>
</ul>
<div class="resp-tabs-container hor_1">
<div id="tabs-1"><?php the_content(); //echo get_post_meta(get_the_ID(), "overview_value", true); ?></div>
<div id="tabs-2"><?php echo get_post_meta(get_the_ID(), "Accomodation", true); ?></div>
<div id="tabs-3"><?php echo get_post_meta(get_the_ID(), "Resort Facilities", true); ?></div>
<div id="tabs-4"><?php echo get_post_meta(get_the_ID(), "Diving", true); ?></div>
<div id="tabs-5"><?php echo get_post_meta(get_the_ID(), "Surfing", true); ?></div>
<div id="tabs-6"><?php echo get_post_meta(get_the_ID(), "Activities", true); ?></div>
<div id="tabs-7"><?php echo get_post_meta(get_the_ID(), "Special", true); ?></div>
</div>
</div>
</div><!-- End demo -->
The script loading is triggered using
<script type="text/javascript">
jQuery(document).ready(function() {
//Horizontal Tab
jQuery('#tabs11').easyResponsiveTabs({
type: 'default', //Types: default, vertical, accordion
width: 'auto', //auto or any width like 600px
fit: true, // 100% fit in a container
tabidentify: 'hor_1', // The tab groups identifier
activate: function(event) { // Callback function if tab is switched
var $tab = jQuery(this);
var $info = jQuery('#nested-tabInfo');
var $name = jQuery('span', $info);
$name.text($tab.text());
$info.show();
}
});
});
</script>
The JavaScript is included well and the same as on Github, only the css for the tabs has changed somewhat and is shown here. I am running it locally on Vagrant so cannot show it online atm. Live site with jQuery UI tabs and no accordion or responsive display is here though. No console errors to really help out so do hope someone here could tell me what I am missing or how I can debug this.
I am attempting to disable a button using an external JavaScript - activated by a submit button <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> ...
I am attempting to disable a button using an external JavaScript - activated by a submit button <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> ...
I'm new to HTML (just started learning at school) and I have a small question about classes and the ability to filter them. Basicially, I'm working on a page of football fixtures, which will look as ...
I'm new to HTML (just started learning at school) and I have a small question about classes and the ability to filter them. Basicially, I'm working on a page of football fixtures, which will look as ...
So, I'm not sure if I should've structured my app different or if I'm doing something fundamentally wrong. I'm a bit confused, but let's explain first things first. In the first navigation level, ...
So, I'm not sure if I should've structured my app different or if I'm doing something fundamentally wrong. I'm a bit confused, but let's explain first things first. In the first navigation level, ...
I'd like to build a website with a full height whatever the user's screen. Scroll is impossible, everything is shown in the page. I tried something like : <body> <div class="header"> ...
I'd like to build a website with a full height whatever the user's screen. Scroll is impossible, everything is shown in the page. I tried something like : <body> <div class="header"> ...