I'm trying to set up a pop up window with a URL to a document each time my Sharepoint site is loaded.
I read that it can be done by adding a content editor web part with a following code to a page:
<script type="text/javascript" src="/_layouts/14/sp.ui.dialog.js">
var options = SP.UI.$create_DialogOptions();
options.title = "My Dialog Title";
options.width = 400;
options.height = 600;
options.url = "http://www.google.com";
SP.UI.ModalDialog.showModalDialog(options);</script>
But I'm getting nothing. Please help identify what am I doing wrong.