Thursday, August 11, 2011

SharePoint PageViewer WebPart Resize Issue

SharePoint OTB PageViewer works fine to display a static web page. But it has a Resizing issue when the source web page has some links which redirects to some other target pages (of more dimentions than source page) within the PageViewer webpart.

Issue/Scinario:
1. A custom search page of height 500x300 is added to pageviewer.
2. The results page with 2 results resize to 300x200.
Now say the result item link redirects to new web page of dimensions 600x500. As pageviewer doesn't support resizing the new page will be shown in 300x200 dimensions.

Solution:
A Content Editor WebPart instead PageViewer WebPart can be used with below iframe and source script to address the resize issue.

Limitations:
The content editor webpart height and width should be set to fixed values(for best page view).







2 comments:

  1. This is not working..I tried to upload this on a SharePoint 2013 page in a script editor and i still see the scroll?
    Please help!

    Thanks,
    Swathi

    ReplyDelete