-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: move properties injection in another file
Signed-off-by: WoodenMaiden <yann.pomie@laposte.net>
- Loading branch information
1 parent
027f802
commit 05a7248
Showing
3 changed files
with
24 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<%-- | ||
Document : about | ||
Created on : Jun 29, 2015, 11:55:56 AM | ||
Author : tagny | ||
--%> | ||
|
||
<%@page contentType="text/html" pageEncoding="UTF-8"%> | ||
${pageContext.ELContext.importHandler.importClass('agrold.config.PropertiesBean')} | ||
<!--Inject system properties inside js--> | ||
<script type="text/javascript"> | ||
// this functions is used parse system parameters inside javascript | ||
// indeed we can't use jsp tags inside javascript, the result comes as raw text | ||
// so we need to parse it if it is equals to null | ||
function parseJsp(text) { | ||
return text === "null" ? null : text; | ||
} | ||
const system_sparqlendpoint = parseJsp('${PropertiesBean.getSparqlEndpoint()}') | ||
const system_faceted_search_url = parseJsp('${PropertiesBean.getFacetedSearchURL()}') | ||
</script> | ||
<script type="text/javascript" src="config/config.js"></script> |