Created
January 23, 2017 06:33
-
-
Save developer-anuragsingh/ebf4050710c7047dfa9f40bf623a99eb to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Hello User!</title> | |
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script> | |
<script type="text/javascript"> | |
$(document).ready(function() { | |
$(".element span").text(function(index, text) { | |
return text.replace('old text', 'next text'); | |
}); | |
}); | |
</script> | |
</head> | |
<body> | |
<div class="element"> | |
<span>This is old text.</span> | |
</div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment