0

We have a document set with Link to Document content types as well as documents. When the users add or edit content they expect to be directed back to the homepage for the docset they just added the content too. Or at the very least the home page of the library.

Instead they are delivered to docsethomepage.aspx without any of the parameters that make that page work.

I found this page which describes the problem and a similar fix in SharePoint 2010, but he says the problem is different in 2013 and no answer for that is given. Overall the problem is that the source parameter in the urls isn't correct.

In the comments someone suggests turning on Library settings > Advanced settings > Launch forms in a dialog but that is only a partial fix. The content types based on Link to Document launch their edit form in a dialog and then close correctly, but the new form doesn't launch in a dialog and it still goes to the wrong place.

Is there a way to fix how the source parameter gets assigned?

Is there a way to fix it so that if a user gets to the docsethomepage.aspx they get redirected to the correct location? But by that time how would I even know?

0

Here is what I did. I added some client side javascript to the docsethomepage.aspx. It checks to see if there is a RootFolder parameter in the querystring. If there is we do nothing.

If there is no RootFolder check the referrer url for a RootFolder parameter, if there is one, replace the document location with a querystring that includes the RootFolder param.

Finally if none of that works, replace the document location with homepage of the library -- it is a better choice than a mangled docsethomepage.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.