Sharepoint Forum

Ask Question   UnAnswered
Home » Forum » Sharepoint       RSS Feeds

Restrict the pop up window only to the Home page.aspx in the Sharepoint

  Asked By: Hunter    Date: Mar 15    Category: Sharepoint    Views: 2158

I am trying to display a pop up window whenever i opened the homepage.aspx
in the share point site . I added the following code :

<BODY scroll="yes" onload="javascript:if (typeof(_spBodyOnLoadWrapper) !=
'undefined') _spBodyOnLoadWrapper();window.open('../test.aspx',

in the master page but the pop up is coming to each and every page where
ever the master page is inherited .

I want to restrict the pop up window to only to the homepage .

Please suggest.



2 Answers Found

Answer #1    Answered By: Emerson Franks     Answered On: Mar 15

Adding this jQuery to the MasterPage will do this.

The query should be placed in a WCE on the homepage.

Answer #2    Answered By: Ned Storm     Answered On: Mar 15

Yah I would just put this in a script tag in a Web Content Editor on
your home  page. Much simpler than modifying master  pages or anything.