Skip to content

Instantly share code, notes, and snippets.

@rumblestrut
Created January 7, 2015 21:59
Show Gist options
  • Select an option

  • Save rumblestrut/83536ce3f35051442abc to your computer and use it in GitHub Desktop.

Select an option

Save rumblestrut/83536ce3f35051442abc to your computer and use it in GitHub Desktop.
Hidden Text
<!DOCTYPE html>
<html>
<head>
<title>Hiding Text</title>
<script>
function expandLoris() {
var expandedParagraph = "Slow lorises are a group of several species of trepsirrhine primates which make up the genus Nycticebus. They have a round head, narrow snout, large eyes, and a variety of distinctive coloration patterns that are species-dependent. The hands and feet of slow lorises have several adaptations that give them a pincer-like grip and enable them to grasp branches for long periods of time. Slow lorises have a toxic bite, a rare trait among mammals.";
document.getElementById("slowLoris").innerHTML = expandedParagraph;
}
</script>
</head>
<body>
<p id="slowLoris">Slow lorises are a group of several species of strepsirrhine primates which make up the genus Nycticebus. <a href =" javascript:void( 0);" onClick =" expandLoris();" ><em> Click for more. </em> </a>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment