svfeinfo = None
# Get Service Info
- list.append(svinfo.getInfoString(iServiceInformation.sProvider))
- list.append(svinfo.getInfo(iServiceInformation.sAspect))
- list.append(hex(svinfo.getInfo(iServiceInformation.sNamespace)))
-
- # Get PIDs
- list.append(svinfo.getInfo(iServiceInformation.sVideoPID))
- list.append(svinfo.getInfo(iServiceInformation.sAudioPID))
- list.append(svinfo.getInfo(iServiceInformation.sPCRPID))
- list.append(svinfo.getInfo(iServiceInformation.sPMTPID))
- list.append(svinfo.getInfo(iServiceInformation.sTXTPID))
- list.append(svinfo.getInfo(iServiceInformation.sTSID))
- list.append(svinfo.getInfo(iServiceInformation.sONID))
- list.append(svinfo.getInfo(iServiceInformation.sSID))
+ if svinfo is not None:
+ list.append(svinfo.getInfoString(iServiceInformation.sProvider))
+ list.append(svinfo.getInfo(iServiceInformation.sAspect))
+ list.append(hex(svinfo.getInfo(iServiceInformation.sNamespace)))
+
+ # Get PIDs
+ list.append(svinfo.getInfo(iServiceInformation.sVideoPID))
+ list.append(svinfo.getInfo(iServiceInformation.sAudioPID))
+ list.append(svinfo.getInfo(iServiceInformation.sPCRPID))
+ list.append(svinfo.getInfo(iServiceInformation.sPMTPID))
+ list.append(svinfo.getInfo(iServiceInformation.sTXTPID))
+ list.append(svinfo.getInfo(iServiceInformation.sTSID))
+ list.append(svinfo.getInfo(iServiceInformation.sONID))
+ list.append(svinfo.getInfo(iServiceInformation.sSID))
+ else:
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+ list.append("N/A")
+
print list
listR = []
define all files in /web to send no XML-HTTP-Headers here
all files not listed here will get an Content-Type: application/xhtml+xml charset: UTF-8
"""
-AppTextHeaderFiles = ['stream.m3u.xml','ts.m3u.xml',]
+AppTextHeaderFiles = ['stream.m3u.xml','ts.m3u.xml','wapwrapper.xml',]
"""
Actualle, the TextHtmlHeaderFiles should contain the updates.html.xml, but the IE then
all files not listed here will get an Content-Type: text/html charset: UTF-8
"""
NoExplicitHeaderFiles = ['getpid.xml','tvbrowser.xml',]
-
+
"""
set DEBUG to True, if twisted should write logoutput to a file.
in normal console output, twisted will print only the first Traceback.
DEBUG = True
-DEBUG = False
+#DEBUG = False
DEBUGFILE= "/tmp/twisted.log"
from twisted.cred.portal import Portal
webif.renderPage(s, self.path, req, sessions[0]) # login?
if self.path.split("/")[-1] in AppTextHeaderFiles:
return http.Response(responsecode.OK,{'Content-type': http_headers.MimeType('application', 'text', (('charset', 'UTF-8'),))},stream=s)
-# elif self.path.split("/")[-1] in TextHtmlHeaderFiles:
-# return http.Response(responsecode.OK,{'Content-type': http_headers.MimeType('text', 'html', (('charset', 'UTF-8'),))},stream=s)
+ elif self.path.split("/")[-1] in TextHtmlHeaderFiles:
+ return http.Response(responsecode.OK,{'Content-type': http_headers.MimeType('text', 'html', (('charset', 'UTF-8'),))},stream=s)
elif self.path.split("/")[-1] in NoExplicitHeaderFiles:
return http.Response(responsecode.OK,stream=s)
else:
html>body tbody.scrollContent {
display: block;
height: 422px;
+ // This is realy bad for resolution below 1280x1024
overflow: auto;
width: 100%;
}
var DBG = true;
-DBG = false;
+//DBG = false;
var url_getvolume = '/web/vol?set=state';
var url_setvolume = '/web/vol?set=set'; // plus new value eq. set=set15
}
function incomingAbout(request) {
if(request.readyState == 4){
+ debug("incomingAbout returned");
var aboutEntries = getXML(request).getElementsByTagName("e2abouts").item(0).getElementsByTagName("e2about");
for (var c =0; c < aboutEntries.length;c++){
var xml = aboutEntries.item(c);
,'serviceAspect': xml.getElementsByTagName('e2serviceaspect').item(0).firstChild.data
,'serviceNamespace': xml.getElementsByTagName('e2servicenamespace').item(0).firstChild.data
,'vPID': xml.getElementsByTagName('e2vpid').item(0).firstChild.data
- ,'vPIDh': parseInt(xml.getElementsByTagName('e2vpid').item(0).firstChild.data,16)
- ,'aPID': xml.getElementsByTagName('e2apid').item(0).firstChild.data
- ,'aPIDh': parseInt(xml.getElementsByTagName('e2apid').item(0).firstChild.data,16)
+ ,'vPIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2vpid').item(0).firstChild.data),16)+" "
+ ,'aPID': xml.getElementsByTagName('e2apid').item(0).firstChild.data+" "
+ ,'aPIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2apid').item(0).firstChild.data),16)+" "
,'pcrID': xml.getElementsByTagName('e2pcrid').item(0).firstChild.data
- ,'pcrIDh': parseInt(xml.getElementsByTagName('e2pcrid').item(0).firstChild.data,16)
+ ,'pcrIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2pcrid').item(0).firstChild.data),16)+" "
,'pmtPID': xml.getElementsByTagName('e2pmtpid').item(0).firstChild.data
- ,'pmtPIDh': parseInt(xml.getElementsByTagName('e2pmtpid').item(0).firstChild.data,16)
+ ,'pmtPIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2pmtpid').item(0).firstChild.data),16)+" "
,'txtPID': xml.getElementsByTagName('e2txtpid').item(0).firstChild.data
- ,'txtPIDh': parseInt(xml.getElementsByTagName('e2txtpid').item(0).firstChild.data,16)
+ ,'txtPIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2txtpid').item(0).firstChild.data),16)+" "
,'tsID': xml.getElementsByTagName('e2tsid').item(0).firstChild.data
- ,'tsIDh': parseInt(xml.getElementsByTagName('e2tsid').item(0).firstChild.data,16)
+ ,'tsIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2tsid').item(0).firstChild.data),16)+" "
,'onID': xml.getElementsByTagName('e2onid').item(0).firstChild.data
- ,'onIDh': parseInt(xml.getElementsByTagName('e2onid').item(0).firstChild.data,16)
+ ,'onIDh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2onid').item(0).firstChild.data),16)+" "
,'sid': xml.getElementsByTagName('e2sid').item(0).firstChild.data
- ,'sidh': parseInt(xml.getElementsByTagName('e2sid').item(0).firstChild.data,16)
+ ,'sidh': parseInt(ownLazyNumber(xml.getElementsByTagName('e2sid').item(0).firstChild.data),16)+" "
};
document.getElementById('BodyContentChannellist').innerHTML = RND(tplAbout, namespace);;
setBodyMainContent('BodyContentChannellist');
+
} catch (e) {
- debug("About parsing Error");
+ debug("About parsing Error" + e);
}
}
-
}
-
-
}
--- /dev/null
+<e2:screen name="WAPwrapper"><e2:element source="redirect"><e2:convert type="web:TextToHTML" /></e2:element></e2:screen>
from Components.config import config
self["file"] = StaticText()
self["localip"] = RequestData(request,what=RequestData.HOST)
+
+class WAPwrapper(WebScreen):
+ def __init__(self, session,request):
+ WebScreen.__init__(self, session,request)
+ from Components.Sources.Config import Config
+ from Components.Sources.StaticText import StaticText
+ self["redirect"] = StaticText()
+ print "request",request
+ for eachKey in self:
+ print "eachKey",eachKey
+
class RestartTwisted(WebScreen):
def __init__(self, session,request):
WebScreen.__init__(self, session,request)
parser = make_parser()
parser.setFeature(feature_namespaces, 0)
parser.setContentHandler(handler)
+ print "__file__: ",__file__
+ print "path: ",path
parser.parse(open(util.sibpath(__file__, path)))
# by default, we have non-streaming pages