You need to sign in to do that
Don't have an account?
Katie Christensen
Image on Customer Portal not displaying
Hello,
I've created a VF page and controller to display an image on the home page layout to our portal users. The image
displays as expected for internal users but I am struggling with making it visible to the portal users. The image is stored in Documents and I¹ve confirmed that it's externally visible but it's still presenting errors.
Class
public with sharing class WebChatController {
public String imageURL{get;set;}
public WebChatController()
{
imageURL='/servlet/servlet.FileDownload?file=';
List< document > documentList=[select name from document where
Name='WebChat'];
if(documentList.size()>0)
{
imageURL=imageURL+documentList[0].id;
}
}
}
VF Page
<apex:page controller="WebChatController" showheader="false" sidebar="false">
<apex:form >
<apex:image url="{!imageURL}">
</apex:image></apex:form>
</apex:page>
Any suggestions?
Thanks in advance,
Katie
I've created a VF page and controller to display an image on the home page layout to our portal users. The image
displays as expected for internal users but I am struggling with making it visible to the portal users. The image is stored in Documents and I¹ve confirmed that it's externally visible but it's still presenting errors.
Class
public with sharing class WebChatController {
public String imageURL{get;set;}
public WebChatController()
{
imageURL='/servlet/servlet.FileDownload?file=';
List< document > documentList=[select name from document where
Name='WebChat'];
if(documentList.size()>0)
{
imageURL=imageURL+documentList[0].id;
}
}
}
VF Page
<apex:page controller="WebChatController" showheader="false" sidebar="false">
<apex:form >
<apex:image url="{!imageURL}">
</apex:image></apex:form>
</apex:page>
Any suggestions?
Thanks in advance,
Katie
JLA.ovh
Check the Folder visibility where you stored the image.You should grant access using a Group where you put the Sites guest user, and add that Group to the folder
Katie Christensen
Yes, I had also confirmed that the Document folder was marked as visible to all users.