aboutsummaryrefslogtreecommitdiff
path: root/pdf-as-web
diff options
context:
space:
mode:
authorrpiazzi <rpiazzi@7b5415b0-85f9-ee4d-85bd-d5d0c3b42d1c>2011-09-29 11:14:57 +0000
committerrpiazzi <rpiazzi@7b5415b0-85f9-ee4d-85bd-d5d0c3b42d1c>2011-09-29 11:14:57 +0000
commitba156bcaecd97fab6d9f273de0d5de2707258ebf (patch)
tree999a2afa5868ce029ab5ade883b65c1a69ebf745 /pdf-as-web
parentbbdadf60ff2d11a4e74ebe3a389ed51944cc1df0 (diff)
downloadpdf-as-3-ba156bcaecd97fab6d9f273de0d5de2707258ebf.tar.gz
pdf-as-3-ba156bcaecd97fab6d9f273de0d5de2707258ebf.tar.bz2
pdf-as-3-ba156bcaecd97fab6d9f273de0d5de2707258ebf.zip
Set src locations to dynamic (checking automatically if pdf-as or test-pdf-as is started)
git-svn-id: https://joinup.ec.europa.eu/svn/pdf-as/trunk@847 7b5415b0-85f9-ee4d-85bd-d5d0c3b42d1c
Diffstat (limited to 'pdf-as-web')
-rw-r--r--pdf-as-web/src/main/webapp/jsp/signupload.jsp26
1 files changed, 14 insertions, 12 deletions
diff --git a/pdf-as-web/src/main/webapp/jsp/signupload.jsp b/pdf-as-web/src/main/webapp/jsp/signupload.jsp
index 57d66e3..f3f8a48 100644
--- a/pdf-as-web/src/main/webapp/jsp/signupload.jsp
+++ b/pdf-as-web/src/main/webapp/jsp/signupload.jsp
@@ -24,6 +24,9 @@
session.removeAttribute(SessionAttributes.DOWNLOAD_URL_FOR_SIGNED_PDF_DOCUMENT);
session.removeAttribute(SessionAttributes.SIGNED_PDF_DOCUMENT);
+ String serverUrl=LocalRequestHelper.getLocalServerAddress(request,response);
+ String baseUrl=LocalRequestHelper.getLocalContextAddress(request,response);
+
//Check if application is started within an iframe from an extern application
String extern = (String)request.getParameter("extern");
boolean startedFromIFrame = false;
@@ -54,7 +57,6 @@
else {
session.setAttribute(SessionAttributes.LANGUAGE, "de");
}
-
}
@@ -142,15 +144,15 @@
if (german) {
%>
<meta name="decorator" content="production_de" />
- <link rel="stylesheet" type="text/css" href="https://www.buergerkarte.at/pdf-as/css/pdfas-styles.css" />
+ <link rel="stylesheet" type="text/css" href="<%=baseUrl%>/css/pdfas-styles.css" />
<% } else { %>
<meta name="decorator" content="production_en" />
- <link rel="stylesheet" type="text/css" href="https://www.buergerkarte.at/pdf-as/css/pdfas-styles.css" />
+ <link rel="stylesheet" type="text/css" href="<%=baseUrl%>/css/pdfas-styles.css" />
<% }
} else {
session.setAttribute("extern", "yes");
%>
- <link rel="stylesheet" type="text/css" href="https://www.buergerkarte.at/pdf-as/css/extern-styles.css" />
+ <link rel="stylesheet" type="text/css" href="<%=baseUrl%>/css/extern-styles.css" />
<% } %>
@@ -391,7 +393,7 @@
fakeFileUpload.appendChild(input);
var img = document.createElement('img');
- img.src = 'https://www.buergerkarte.at/pdf-as/images/durchsuchen.png';
+ img.src = '<%=baseUrl%>/images/durchsuchen.png';
img.id = 'buttonimage';
var fakeButton = document.createElement('input');
@@ -442,12 +444,12 @@
//Show the fake image/button as it would be focused (mouse over)
function focusButton() {
- document.getElementById('buttonimage').src = 'https://www.buergerkarte.at/pdf-as/images/durchsuchen_aktiv.png';
+ document.getElementById('buttonimage').src = '<%=baseUrl%>/images/durchsuchen_aktiv.png';
}
//Show the fake image/button as it would be unfocused (mouse out)
function unfocusButton() {
- document.getElementById('buttonimage').src = 'https://www.buergerkarte.at/pdf-as/images/durchsuchen.png';
+ document.getElementById('buttonimage').src = '<%=baseUrl%>/images/durchsuchen.png';
}
//Change some size settings when IE7 is found
@@ -768,10 +770,10 @@
<div class="rechts" id="sign" style="display:block">
<div class="rechtsinhalt" id="signintern">
<div class="rechtslinks">
- <img src="https://www.buergerkarte.at/pdf-as/images/onlineBKU.png" alt="Chip-Karte" id="Karte" />
+ <img src="<%=baseUrl%>/images/onlineBKU.png" alt="Chip-Karte" id="Karte" />
</div>
<div class="rechtsrechts">
- <img src="https://www.buergerkarte.at/pdf-as/images/mobileBKU.png" alt="Handy" id="Handy"/>
+ <img src="<%=baseUrl%>/images/mobileBKU.png" alt="Handy" id="Handy"/>
</div>
<div class="rechtslinks">
<input type="submit" name="<%= FormFields.FIELD_CONNECTOR_SMARTCARD %>" value="<fmt:message key="signupload.signwithcard"/>" alt="Signatur mit Karte" onclick="return submitForm(this)"></input>
@@ -805,7 +807,7 @@
<div style="font-size:75%"><fmt:message key="nullrequestpage.localbku.advice"/></div>
<div class="pdfassmallverticalspace"></div>
</div>
- <div id="backlink" align="left"><a href="https://www.buergerkarte.at/pdf-as/" target="_parent"><fmt:message key="common.cancel"/></a></div>
+ <div id="backlink" align="left"><a href="<%=baseUrl%>/" target="_parent"><fmt:message key="common.cancel"/></a></div>
</div>
</div>
<!-- Fake signature buttons for the case an error occured and this error has to be displayed
@@ -814,10 +816,10 @@
<div class="rechts" id="downloadsignbuttons" style="display:none">
<div class="rechtsinhalt" id="downloadsignbuttonsintern">
<div class="rechtslinks">
- <img src="https://www.buergerkarte.at/pdf-as/images/onlineBKU.png" alt="Chip-Karte" id="Karte"/>
+ <img src="<%=baseUrl%>/images/onlineBKU.png" alt="Chip-Karte" id="Karte"/>
</div>
<div class="rechtsrechts">
- <img src="https://www.buergerkarte.at/pdf-as/images/mobileBKU.png" alt="Handy" id="Handy"/>
+ <img src="<%=baseUrl%>/images/mobileBKU.png" alt="Handy" id="Handy"/>
</div>
<div class="rechtslinks">
<input type="submit" name="<%= FormFields.FIELD_CONNECTOR_SMARTCARD %>" value="<fmt:message key="signupload.signwithcard"/>" alt="Signatur mit Karte" onclick="return submitForm(this)" disabled="disabled"></input>