(function () {
    var bookmarkedState = YAHOO.util.History.getBookmarkedState("v");
    var initialState = bookmarkedState || "";
	//var initialState = "";

    YAHOO.util.History.register("v", initialState, function (state) {
						
		getVideoAndPlay(state);
		//Use the videoID passed in the state
		//playVideo(state,stripslashes(title));	
	    });   

    // Use the Browser History Manager onReady method to instantiate the TabView widget.
    YAHOO.util.History.onReady(function () {
        var currentState;      
        currentState = YAHOO.util.History.getCurrentState("v");
    });

    try {
        YAHOO.util.History.initialize("yui-history-field", "yui-history-iframe");
    } catch (e) {
    }

})();

