# How to personalize the image large view and interaction (footer)

The present article will show how it is possible to open the parent Salesforce record of an image from the **Large View** mode.

We will make use of an Apex Class Controller to define the Salesforce record and a Visualforce Page to display the SharinPix Image Search.

## Demo in action

* An image is clicked upon.

<figure><img src="/files/nlfaCviSXAUeuiOsbl0e" alt=""><figcaption></figcaption></figure>

* The **Large View** mode of the selected image is then activated.

<figure><img src="/files/umMNERgP089tMBdJurxy" alt=""><figcaption></figcaption></figure>

* The defined **Salesforce record** can be opened by clicking on the icon as shown below.

<figure><img src="/files/y0ojzaduesQzwBrjoyMP" alt=""><figcaption></figcaption></figure>

* After clicking on the above icon, you will be redirected to the parent Salesforce record of the current image.

## Apex Class Controller

The code snippet below illustrates how the implementation of the Apex Class Controller.

```apex
  public class SharinPixSearchPage {
    public Map<String, Object> params;
    private sharinpix.Client clientInstance = sharinpix.Client.getInstance();
  
    public SharinPixSearchPage(ApexPages.StandardController controller) {
      Map<String, Object> query = new Map<String, Object> {
        'q' =>  '*'
      };
  
      params = new Map<String, Object> {
        'path' => 'search?search_bar=true&q='+clientInstance.token(query),
        'salesforceBaseUrl' => 'https://custom-domain.my.salesforce.com'
      };
    }
    
    public String getParameters() {
      return JSON.serialize(params);
    }
  }
```

* You need to set the **salesforceBaseUrl** key to the url that corresponds to your own Salesforce Organization domain.

```
'salesforceBaseUrl' => 'https://your-own-domain.my.salesforce.com'
```

## Visualforce Page

* The code snippet below illustrates the implementation of the Visualforce Page used in this article to display the SharinPix Image Search.

```html
  <apex:page docType="html-5.0" cache="false"
    showHeader="false"
    sidebar="false" 
    standardStylesheets="false"
    standardController="Account"
    extensions="SharinPixSearchPage"
    applyHtmlTag="false"
    applyBodyTag="false">
      
    <apex:canvasApp developerName="Albums" width="100%" height="500px" parameters="{! parameters }"/>
  </apex:page>
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.sharinpix.com/documentation/features/search-images/how-to-personalize-the-image-large-view-and-interaction-footer.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
