You need to sign in to do that
Don't have an account?

Managing specific site-related content in a shared visualforce page
Hello,
I manage several sites and some visualforce page is shared.
Since in every site there's need for specific, targeted content, e.g.. the footers, I put some code like:
<c:EGHomepagetitle rendered="{!$Site.Name = 'Egitto'}" />
<c:LYHomepagetitle rendered="{!$Site.Name = 'Libia'}" />
<c:ABCfooter rendered="{!$Site.Name = 'ABC'}" />
<c:DEFfooter rendered="{!$Site.Name = 'DEF'}" />
Thus, I've references to components.
In order to manage pieces of codes in the main body, is there any way to achieve the same result without any external reference?
I'd like to have a std visualforce page where some text&image are shown only when the page is used under a specific site.
I found the solution:
<apex:outputPanel rendered="{!$Site.Name='XYZ'}">
</apex:outputPanel>
thanks to a guy at salesforce.com
All Answers
Have a look at the Site template option. I think it will do what you want.
thanks.
Actually I've been using the <apex:composition> + <apex:define>.
Now I'd like to avoid increasing the number of components for smaller pieces of code.
I found the solution:
<apex:outputPanel rendered="{!$Site.Name='XYZ'}">
</apex:outputPanel>
thanks to a guy at salesforce.com