Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Using Modules a...Using Modules a...collapse tabscollapse tabs
Previous
 
Next
New Post
5/22/2014 10:27 AM
 

Hi any JQuery Gurus out there,

I am trying to adapt the dnntabs plugin demo on http://uxguide.dotnetnuke.com/UIPatterns/Tabs.aspx to load with only the tabs i.e. no content visibile on load (it always shows the first tab content as default.
I want to create multiple rows of Icons that only show their content when clicked, also only 1 row at a time should be open at any time, something I had working with JQuery UI and VS,  Unfortunatly this will not work very well in DNN due to a conflict (somewhere).

Hence trying to use DnnPlugin. I have tried using the ususal javascript? but no avail.

<script type="text/javascript">
      jQuery(function ($) {
          $('#tabs-demo,#tabs-demo2').dnnTabs({ collapsible: true,   active: 'none', selected: -1  });
      });    
</script> 

<div class="dnnForm" id="tabs-demo">
        <ul class="dnnAdminTabNav">
            <li><a href="#ChristopherColumbus">Christopher Columbus</a></li>
            <li><a href="#IsaacNewton">Isaac Newton</a></li>
            <li><a href="#JohannesGutenberg">Johannes Gutenberg</a></li>
        </ul>
        <div id="ChristopherColumbus" class="dnnClear">
            <img src="<%=ResolveUrl("Images/498px-Christopher_Columbus.PNG") %>" alt="Christopher Columbus" width="32%" class="dnnLeft" />
            <div class="dnnRight" style="width:62%;margin-left:2%">
              <h1>Christopher Columbus</h1>
                <p>Italian navigator, colonizer and explorer whose voyages led to general European awareness of the American continents.</p>
            </div>
        </div>
        <div id="IsaacNewton" class="dnnClear">
            <img src="<%=ResolveUrl("Images/GodfreyKneller-IsaacNewton-1689.jpg") %>" alt="Isaac Newton" width="32%" class="dnnLeft" />
            <div class="dnnRight" style="width:62%;margin-left:2%">
              <h1>Isaac Newton</h1>
                <p>English physicist, mathematician, astronomer, natural philosopher, alchemist, and theologian. His law of universal gravitation and three laws of motion laid the groundwork for classical mechanics.</p>
            </div>
        </div>
        <div id="JohannesGutenberg" class="dnnClear">
            <img src="<%=ResolveUrl("Images/Gutenberg.jpg") %>" alt="Johannes Gutenberg" width="32%" class="dnnLeft" />
            <div class="dnnRight" style="width:62%;margin-left:2%">
              <h1>Johannes Gutenberg</h1>
                <p>German printer who invented the mechanical printing press.</p>
            </div>
        </div>
  </div>

<div class="dnnForm" id="tabs-demo2">

????????????/etc etc

 

 
New Post
5/26/2014 9:41 AM
 
I suspect your issue is with tab persistence - there is an event handler wired up with records the state of tabs clicked in panels/tabs during usage, so when you return to a page everything is as it was on your last visit. This is likely interfering with any logic you are adding to change the tab states - there is actually a small enhancement in 7.3.0 which will allow better support for initial state and to disable this cookie remembering - you can view it at https://github.com/dnnsoftware/Dnn.Pl... perhaps it will help you

Buy the new Professional DNN7: Open Source .NET CMS Platform book Amazon US
 
New Post
5/28/2014 9:39 AM
 

Interesting cathal.

Ok I was able to replace the code in my JQuery.js with the version on GIThub without any difference, I assume this is what I was supposed to do?.

Any other tip Cathal, the only thing not

 
New Post
5/28/2014 10:31 AM
 
My original attempt was with a JQuery UI version and this actually works better than the DNN  Tabs version, in that it loads 2 rows of Tabs (I am using  font icons in each horizontal row rather than tab styles)  correctly with all content panes collapsed. When you click an icon/tab then it shows the correct  content pane with its subset of child icons.
The only thing it does not do is collapse any open panes in row 1 for e.g  when a new icon in row 2  is selected.
I must say that I have it working perfectly in VS and elsewhere it is just DNN that has this quirk. Any advice would be really appreciated.

This is the JQuery
  <script type="text/javascript">
$(function () {
    $("#tabs-services-row1, #tabs-services-row2").tabs({
        collapsible: true,
        active: 'false', //none
        selected: -1,
        fx: { height: 'toggle', duration: 'normal' }
    });
    return false;
});

$(function () {

        $("#tabs-services-row1 ul.toptabs li a").click (function(){
             $( "#tabs-services-row2" ).tabs('option', 'selected', -1);
        });
       
        $("#tabs-services-row2 ul.toptabs li a").click (function(){
            $( "#tabs-services-row1," ).tabs('option', 'selected', -1);
        });

             


        $("#tabs-services-row1.tab-pane a.btn-tabs-services-close").click (function(){
            $( "#tabs-services-row1" ).tabs('option', 'selected', -1);
            return false;
        });


});
</script>
 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Using Modules a...Using Modules a...collapse tabscollapse tabs


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out