x x x
x
Only portrait mode is currently supported - please rotate your device.

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

HTML
<script>
$('.tab-control-button.0').click(function() {
	// Hide all except div 0
	$('div.cardSection').css('display', 'flex');
	$('div.cardSection1').css('display', 'none');
	$('div.cardSection2').css('display', 'none');
	$('div.cardSection3').css('display', 'none');
	$('div.cardSection4').css('display', 'none');
	$('div.cardSection5').css('display', 'none');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'none');
});

$('.tab-control-button.1').click(function() {
    // Hide all except div 1
	$('div.cardSection').css('display', 'none');
	$('div.cardSection1').css('display', 'flex');
	$('div.cardSection2').css('display', 'none');
	$('div.cardSection3').css('display', 'none');
	$('div.cardSection4').css('display', 'none');
	$('div.cardSection5').css('display', 'none');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'none');
});

$('.tab-control-button.2').click(function() {
    // Hide all except div 2
	$('div.cardSection').css('display', 'none');
	$('div.cardSection1').css('display', 'none');
	$('div.cardSection2').css('display', 'flex');
	$('div.cardSection3').css('display', 'none');
	$('div.cardSection4').css('display', 'none');
	$('div.cardSection5').css('display', 'none');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'flex');
});

$('.tab-control-button.3').click(function() {
    // Hide all except div 3
	$('div.cardSection').css('display', 'none');
	$('div.cardSection1').css('display', 'none');
	$('div.cardSection2').css('display', 'none');
	$('div.cardSection3').css('display', 'flex');
	$('div.cardSection4').css('display', 'none');
	$('div.cardSection5').css('display', 'none');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'flex');
});

$('.tab-control-button.4').click(function() {
    // Hide all except div 4
	$('div.cardSection').css('display', 'none');
	$('div.cardSection1').css('display', 'none');
	$('div.cardSection2').css('display', 'none');
	$('div.cardSection3').css('display', 'none');
	$('div.cardSection4').css('display', 'flex');
	$('div.cardSection5').css('display', 'none');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'flex');
});
$('.tab-control-button.5').click(function() {
    // Hide all except div 5
	$('div.cardSection').css('display', 'none');
	$('div.cardSection1').css('display', 'none');
	$('div.cardSection2').css('display', 'none');
	$('div.cardSection3').css('display', 'none');
	$('div.cardSection4').css('display', 'none');
	$('div.cardSection5').css('display', 'flex');
	// Hide mentor filter
	//$('.filterByStrength').css('display', 'none');
});
</script>


HTML
<script>
// REPLACING ALL THE AUTOMATICALLY-GENERATED PROFILE LINKS IN SEARCH POPUP WITH PROFILE LINKS:
const replacePopupLinks = () => {
  let links = Array.from(document.getElementById("custom-user-search-results-dialog").getElementsByTagName("A"));
  links.forEach(link => {
    if (link.href.includes('/display/~')) {
      let email = link.href.split('/display/~').pop();
      link.href = '/display/MSCOM/Company+Page?company=' + email;
    }})
}

const popupReadyPolling = () => {
  if (document.getElementById("custom-user-search-results-dialog")) {
    replacePopupLinks();
  } else {
    setTimeout(popupReadyPolling, 200);
  }
}

// Set the polling function to start when page is done loading: 
window.addEventListener('DOMContentLoaded', () => {
	var searchBars = document.getElementsByClassName("custom-user-search-form");
	for(var i = 0; i < searchBars.length; i++) {
    	searchBars[i].addEventListener("submit", popupReadyPolling)
	}
});

</script>

...