on 12-24-2012 1:51 PM
Hi,
Is there any way to add header and footer for sup hwc app?
I have tried to inject code from Custom.js like following :
In function customBeforeShowScreen :
if(screenToShow =='PODetails')
{
var form = document.forms[screenToShow + "Form"];
if (form) {
// header
var topOfFormElem = document.getElementById("topOf" + screenToShow + "Form");
if (topOfFormElem) {
//topOfFormElem.innerHTML = "<center><img id='ImgSylogo'src='./images/star.png'/></center><br/>";
//topOfFormElem.innerHTML = "<center><p>PODetails Header</p></center>";
topOfFormElem.innerHTML ="<div data-theme='e' data-role='header'>";
topOfFormElem.innerHTML +="<h3>Products</h3></div>";
// footer
var bottomOfFormElem = document.getElementById("bottomOf" + screenToShow + "Form");
bottomOfFormElem.innerHTML = "<center><p>Copyright 2012, Dev Center</p></center>";
}
}
}
i have attached screenshot for same which i have taken android emulator.
Pleas guide me on this?
Regards,
Swapnil.
Hi Swapnil,
are you getting the footer correctly? if no then do below change mentioned in bold font...
var bottomOfFormElem = document.getElementById("bottomOf" + screenToShow + "Form");
if(bottomOfFormElem) {
bottomOfFormElem.innerHTML = "<center><p>Copyright 2012, Dev Center</p></center>";
}
Regards,
Jitendra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
88 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.