+ Start a Discussion
Filip Poverud 4Filip Poverud 4 

Create & Edit Visualforce Pages - Unable to complete challenge


Challenge not yet complete in DreamHouse
The page does not have the 'showHeader' attribute set to false

If we look at the note in this module:

Beyond the Basics
Note that both the sidebar and showHeader attribute have no effect in Lightning Experience, and that there’s no way to suppress the Lightning Experience header. Although the default value of showHeader is true, it has no effect in Lightning Experience.
The page still includes some Salesforce style sheets, which let you match Salesforce choices for fonts, size, and so on. To suppress all Salesforce output, add standardStylesheets="false" to remove the styles as well.

We see that showHeader is obsolete and there is no reason to add it.

In the challenge it is specified that the standard SalesForce header should not be displayed:

It must NOT display the standard Salesforce header

I assume the module was created for Classic or did I miss something basic regarding this attribute in LE ? I'm currently on SU19.

with Regards
Filip Poverud
Best Answer chosen by Filip Poverud 4
Khan AnasKhan Anas (Salesforce Developers) 
Hi Filip,

Greetings to you!

You are absolutely correct. Visualforce pages always display with the standard Lightning Experience user interface when they run in Lightning Experience. There’s no way to suppress or alter the Lightning Experience header or sidebar. In particular, the showHeader and sidebar attributes of <apex:page> have no effect on Visualforce pages when displayed in Lightning Experience.

However, to pass this particular challenge you need to use showHeader attribute in visualforce page. If you don't use showHeader attribute it won't allow you to pass the challenge.
<apex:page showHeader="false" title="DisplayImage" >
    <apex:image value="https://developer.salesforce.com/files/salesforce-developer-network-logo.png" height="100" width="300" />

I hope it helps you.

Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.

Thanks and Regards,
Khan Anas