Created
February 15, 2011 15:52
-
-
Save arantius/827683 to your computer and use it in GitHub Desktop.
This file contains 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 xmlns:ng="http://angularjs.org"> | |
<head> | |
<title>Angular Title Test</title> | |
<script src="http://code.angularjs.org/angular-0.9.10.min.js" ng:autobind></script> | |
</head> | |
<body> | |
<script type="text/javascript"> | |
angular.service('title_changer', function($document) { | |
alert('title_changer service running'); | |
$document.title = 'Changed title!'; | |
}, {$inject: ['$document'], $eager: true}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment