Using Page Viewer Web Part to display a specific portion of a page

What is the best way to display only a specific portion of a page in a page viewer web part. i.e., without displaying the header and the footer of the page inside the Page Viewer.
torameshAsked:
Who is Participating?
 
raybiesConnect With a Mentor Commented:
the pageviewer webpart (PVWP) is just an iframe... yup pretty pathetic. MS could have just add a parameter to the content editor web part.

Anyway, you can't. What ever the page looks like is how you get it, except in a frame. You can do some programming and use an HttpRequest object client or serverside, to get the content at certain points. But you can't do didley  with the PVWP
0
 
torameshAuthor Commented:
But isn't it possible to retrict the html displayed in the "iframe" by specifying a start tag and end tag. i.e., create a web part, get the start tage and end tag from users and display html only within those tags? Is this possible or am I just going in the wrong direction?
0
 
williamcampbellConnect With a Mentor Commented:
Well you have access to the DOM so maybe you getElementById and set the tags you don't want to see to hidden.

/gotnuthin
0
Cloud Class® Course: Microsoft Exchange Server

The MCTS: Microsoft Exchange Server 2010 certification validates your skills in supporting the maintenance and administration of the Exchange servers in an enterprise environment. Learn everything you need to know with this course.

 
raybiesConnect With a Mentor Commented:
Yes, that's what I mean by "programming", but not with the PVWP.
Chances are you'll have to look for a specific string.

So your JS/C# will be like.

HttpObj.Response.Substring(HttpObj.Response.IndexOf("myStartStr"), HttpObj.Response.IndexOf("myEndStr"))
0
 
raybiesCommented:
Question answered.
0
 
raybiesCommented:
Vee_Mod:

ID:24024495 answered the question.
ID:24024645 elaborated on the answer.
ID:24024837 elaborated on the answer.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.