Previous
Next
');jQuery(".next").on('click', function(evt){openHubCTA(nextObject);hub.empty();});} else {var more = jQuery("#loadmore");if (more.text() == "No More Articles") return false;more.text("Loading ...");$page = more.data('page');searchdata = jQuery("#loadmore").data();mapInputValues();//ajaxLoadArticles();//setNextBack();}}/** * Set close button. Will rebind the event listener. */function setCloseButton() {closebtn = jQuery("#hubclose");closebtn.on('click', function(){//toggleFilter();//window.history.go(-1);closeArticle();});}function closeArticle() {var stateObj = null;history.pushState(stateObj,'','/business-resources');artholder.empty();hideitems = jQuery(".featuredarticles, .articleresults");hideitems.removeClass("closed");toggleFilter();}/** * Load response data from wordpress ams article into page. * hides the ctas. */function displayHubArticle(response) {artholder.removeClass('loading');artholder.html(response);document.title = artholder.find("#hubtitle").text();// change og metajQuery('meta[property="og:title"]').remove(); jQuery('head').append( '' );scrollToID(jQuery("body"));}/** * opens and closes the filter. IF force is true it will close it. */function toggleFilter(force){var force = typeof force !== 'undefined' ? force : false;var filter = jQuery("#filters");var closebutton = jQuery("#filter-close");if(filter.hasClass("open") || force) {filter.removeClass("open");closebutton.text("Open");} else {filter.addClass("open");closebutton.text("Close");}}/** * pass post id to call wordpress admin-ajax to fetch article. * ele - int - post_id of the ams article id. */function openHubCTA(ele) {var artid = ele.data('id');if (artid) {var stateObj = {id:artid};getHubArticle(artid);toggleFilter(true);history.pushState(stateObj,'',ele.find('a').attr('href'));}}/** * refresh all cta listeners */function renewCTAListener() {var links = jQuery('.hubcta:not(.default) a');links.off();links.on('click', function(evt){evt.preventDefault();});var ctablocks = jQuery('.hubcta:not(.default)');ctablocks.off();ctablocks.on('click', function(evt) {openHubCTA(jQuery(this));});var webinarlinks = jQuery('.hubcta.default');webinarlinks.on('click', function(){location.href = jQuery(this).find('a').attr('href');});}/** * Popstate listener. Used to change url without reloading page. */window.onpopstate = function(event) {if (event.state) {getHubArticle(event.state['id']);} else {closeArticle();//artholder.empty();//hideitems = jQuery(".featuredarticles, .articleresults");//hideitems.removeClass("closed");}};function fadeAtHeight(obj, h) {var objtop = h.offset().top+190;var objbot = objtop + h.height();jQuery(window).scroll(function(){var doctop = jQuery(window).scrollTop();var docbot = doctop + jQuery(window).height();if (objbot <= docbot) {obj.addClass("hidefilter");} else {obj.removeClass("hidefilter");}});}function filterLoadLocation() {var filterdiv = jQuery("#filters");fadeAtHeight(jQuery("#loading"), filterdiv);}jQuery(document).ready(function(){jQuery("#loadmore").data('page',0);searchdata = jQuery("#loadmore").data();artholder = jQuery("#articleholder");initArticleLoad();jQuery("#loadmore").on('click touch', function(evt){evt.preventDefault();$this = jQuery(this);$this.text("Loading ...");$page = $this.data('page');searchdata = jQuery("#loadmore").data();mapInputValues();ajaxLoadArticles();});jQuery("#filters input, #filters select").on('change', function(){searchdata.page = 0;mapInputValues();ajaxChangeArticles();});// scroll tool.jQuery(".view-results").on('click',function() {scrollToID(jQuery('#featuredarticlesholder'));});jQuery("#filter-close").on('click', function(evt){evt.preventDefault();toggleFilter();});getHubArticle(40296);toggleFilter(true);//setCloseButton(true);filterLoadLocation();renewCTAListener();});Select one or more filters to access resources for your specific needs.
Featured Articles
Load More
Get to know NFIB
NFIB is a member-driven organization advocating on behalf of small and independent businesses nationwide.
Or call us today
1-800-634-2669
© 2001 - 2024 National Federation of Independent Business. All Rights Reserved. Terms and Conditions | Privacy