SharePoint – Search results DispForm.aspx Redirect

When you do a search in SharePoint 2010 you get the results listed with a link to the Default DispForm.aspx.


But this opens up the ugly Standard Form.


While you might have put a lot of efforts in designing a Custom Form.


Solution is simple :

Add a redirect to the Standard Form to the Custom Form and you are done. Using the jQuery().SPServices library.


Code is here :

<script language="javascript" src="/sites/Scripts/jquery.SPServices-0.7.2.min.js"></script><script type="text/javascript">


// alert(jQuery().SPServices.Version());

// Get Activity ID from URL
   var queryStringVals = jQuery().SPServices.SPGetQueryString();
   var ID = queryStringVals["ID"];

//alert (ID);

var URL = '' + ID;

//alert ('We go to this ' + URL);

window.location.href = URL;

Enjoy !!


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: