ALL TAGS

Thought Leadership

Show All Tags
Show Less Tags
"; } }); $("#blogs-list").html(html); startParam = parseInt(startParam) + parseInt(noOfLoadMoreItems); if (typeof(filterOffset) != "undefined") { $('#load-more').attr( "data-filter-offset", startParam); } } }); } var loadMoreOffset = $('#load-more').data("offset"); var startParam = 15; if (typeof(loadMoreOffset) != "undefined") { startParam = 15 - parseInt(loadMoreOffset); } /** On load set page number **/ if (window.location.href.indexOf('page=') > -1) { var pageURL = window.location.href; pageURL = pageURL.split('page='); pageURL = pageURL[1]; var hrefV = window.location.href; var url = hrefV.split('='); var finalURL = parseInt(url[1]) + 1; $('#load-more a').attr('href', "?page=" + finalURL); } else { $('#load-more a').attr("href", "?page=2"); } //var filterFlag = true; /** Load certain page data if URL has page number **/ if (window.location.href.indexOf('page=') > -1) { // On page load var noOfLoadMoreItems = 15; var pageType = "relatedTag"; var buttonTxt = "Load More"; var pagePath = "\/content\/splunk\u002Dblogs\/en_us\/tag\/thought\u002Dleadership"; var html = ""; var value = "thought\u002Dleadership"; var languageLocale = $('body').attr('lang').toLowerCase().replace('-', '_'); var filterOffset = $(this).attr("data-filter-offset"); let url = window.location.href; let href = url.split('='); if (typeof(filterOffset) != "undefined") { startParam = filterOffset; // filterFlag = false; } else { startParam = (parseInt(href[1]) * 15) - 15; } ajaxTagList(); // load more click when page= $('#load-more') .click( function() { var hrefV = $(this).find('a').attr('href'); var url = hrefV.split('='); var finalURL = parseInt(url[1]) + 1; $(this).find('a').attr('href', "?page=" + finalURL); var noOfLoadMoreItems = 15; var pageType = "relatedTag"; var buttonTxt = "Load More"; var pagePath = "\/content\/splunk\u002Dblogs\/en_us\/tag\/thought\u002Dleadership"; var html = ""; var value = "thought\u002Dleadership"; var languageLocale = $('body').attr('lang').toLowerCase().replace('-', '_'); var filterOffset = $('#load-more').attr("data-filter-offset"); if (typeof(filterOffset) != "undefined") { startParam = filterOffset; // filterFlag = false; } ajaxTagList(); }); } else { $('#load-more') .click( function() { var hrefV = $(this).find('a').attr('href'); var url = hrefV.split('='); var finalURL = parseInt(url[1]) + 1; $(this).find('a').attr('href', "?page=" + finalURL); var noOfLoadMoreItems = 15; var pageType = "relatedTag"; var buttonTxt = "Load More"; var pagePath = "\/content\/splunk\u002Dblogs\/en_us\/tag\/thought\u002Dleadership"; var html = ""; var value = "thought\u002Dleadership"; var languageLocale = $('body').attr('lang').toLowerCase().replace('-', '_'); var filterOffset = $(this).attr("data-filter-offset"); if (typeof(filterOffset) != "undefined") { startParam = filterOffset; // filterFlag = false; } $ .ajax({ type: "GET", url: "/bin/splunk/blogs/listing.json", dataType: "json", data: { request: pageType, value: value, startParam: startParam, endParam: noOfLoadMoreItems, pagePath: pagePath, languageLocale: languageLocale }, success: function(response) { if (response.length <= noOfLoadMoreItems) { $('#load-more').remove(); } $(response) .each( function(i, data) { if (i < noOfLoadMoreItems) { html += "
"; html += ""; html += "
"; html += "
"; html += "" + data.categoryTitle + ""; html += "
"; html += "
"; html += "" + data.blogTitle + ""; html += "
"; html += "
"; if (pageType != "author") { html += ""; html += "\"\" By " + data.authorName + ""; html += ""; } html += "" + data.date + ""; html += "
"; html += "
"; html += "
"; } }); $("#blogs-list").append(html); startParam = parseInt(startParam) + parseInt(noOfLoadMoreItems); if (typeof(filterOffset) != "undefined") { $('#load-more').attr( "data-filter-offset", startParam); } } }); }); }