Salesforce | How to add page header image in a visualforce page?

|
| By Webner

We can add the page header image in a visualforce page using following apex tag:

<apex:image id="" value="" width="" height=""/>

In “value” Field of tag we give the url of the image where image is located. Image may be located in static resources in Salesforce or somewhere outside (publicly accessible with a url).

If image is in Static Resources in salesforce then syntax to access an image is like this:

$Resource.HeaderLogo

Here HeaderLogo is the name of the image. So final look of the image tag is as below:

<apex:image id="theImage" value="{!$Resource.HeaderLogo}" width="200" height="200"/>

Webner Solutions is a Software Development company focused on developing CRM apps (Salesforce, Zoho), LMS Apps (Moodle/Totara), Websites and Mobile apps. If you need Salesforce customization, App development or any other software development assistance please contact us at salesforce@webners.com

Leave a Reply

Your email address will not be published. Required fields are marked *