function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
tonitonitonetonitonitone 

embed VF page in page layout, but links to Contact object opens within frame.

I have a VF page embedded in a standard page layout. The VF page has a pageBlockTable which calls the Contact id, which displays the Contact Name and a link to the Contact detail page. This is all fine and dandy, except the links to the Contact detail page opens within the VF frame, and not reloaded in the browser window.

Here's the line of code I'm referring to:

Code:
<apex:column headerValue="Contact Detail" value="{!item.Contact__c}" />

 
I tried hijacking all the links on the page by coding this at the top of the VF page --
Code:
<BASE TARGET="_top" />

 
but then that messes up the rerender functionality of the other links on the page.

Any ideas??
tonitonitonetonitonitone
So I worked around the issue by doing this --
Code:
<apex:column headerValue="Participant">
      <a href="/{!item.Contact__c}" target="_top">{!item.FirstName__c} {!item.LastName__c}</a>
     </apex:column>

 
But IMHO, this sounds like a bug. The redirection target for the apex:pageBlockTable links to Contact Details should be corrected to reload the entire page, and not within the frame.
mtbclimbermtbclimber
Not quite that simple I am afraid.

Another possible solution would be on the page layout component definition to indicate that all links should target top.  It's conceivable that other users might actually want links to load within the iframe so making it an option may be worthy of consideration.

Whichever option you prefer I encourage you to create an idea on the idea exchange for this feature request.


Message Edited by mtbclimber on 08-23-2008 10:29 AM