×
The 2025 Client Survey is now open! Responses will be accepted up until 10/31. Please feel free to share this link within your organization and we thank you in advance for your participation!

Custom site welcome page

LabKey Support Forum (Inactive)
Custom site welcome page johann pellet  2020-04-02 03:07
Status: Active
 

Hi all,

I would like more information about how we should proceed to customize an alternative welcome page (Labkey 19.3).
Despite the documentation here: (https://www.labkey.org/Documentation/19.3/wiki-page.view?name=customizeLook) and the help bubble in the Look and Feel Settings labkey page, it's not clear for me how to proceed.

Help buble:
The relative URL of the page, either a full LabKey view or simple HTML resource, to be loaded as the welcome page. The welcome page will be loaded when a user loads the site with no action provided (i.e. https://www.labkey.org). This is often used to provide a splash screen for guests. Note: do not include the contextPath in this string. For example: /myModule/welcome.view to select a view within a module, or /myModule/welcome.html for a simple HTML page in the web directory of your module.

What I tried is

  • to create in /usr/local/labkey/labkey/modules a new folder myModule. Into this folder I created a folder views and a file in views/welcome.html
  • in the Look and feel settings page I choose "myModule.welcome" .
    I also tried with other relative URL without success.

Thank you for your help.

Johann

 
 
chetc (LabKey Support) responded:  2020-04-17 14:50
Status: Closed

Hello Johann,

I tried following the steps

  1. Created myModule/views/welcome.html in labkey/modules
  2. Restarted tomcat
  3. In the look and feel settings page I set "Alternative site welcome page" to "/myModule/welcome.view" (viewEntry.png)
  4. Hit Save

The welcome page will be loaded when a user loads the site with no action provided (i.e. https://www.labkey.org). So in my case this was http://localhost:8080/labkey/. See (view.png). This loads a view as expected.

If you want a simple HTML page

"or /myModule/welcome.html for a simple HTML page in the web directory of your module." --> From the docs. This could use a bit of clarification, and we can get the doc updates.

But to have the simple HTML page you need to

  1. Add a another folder in in myModule called web
  2. Within web create another folder called myModule and add your welcome.html here
  3. Should look like
  • myModule
    ---view
    ---web
    ------myModule
    ---------welcome.html
  1. In the look and feel settings page I set "Alternative site welcome page" to "/myModule/welcome.html" (htmlEntry.png)
  2. You should see html.png

This doc lays out the structure of a module.
https://www.labkey.org/Documentation/wiki-page.view?name=moduleDirectoryStructures

Questions

  1. in the Look and feel settings page I choose "myModule.welcome". Did you select this by setting "Alternative site welcome page" to "/myModule/welcome.view"?
  2. What was the other relative URL you tried?

Thanks,
Chet