Changeset 504:454a42f4c369 in documentViewer
- Timestamp:
- Feb 16, 2012, 3:51:17 PM (13 years ago)
- Branch:
- elementtree
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
zpt/viewer_xml.zpt
r503 r504 3 3 <html xmlns="http://www.w3.org/1999/xhtml" 4 4 tal:define="docinfo options/docinfo; pageinfo options/pageinfo; viewMode pageinfo/viewMode; 5 tocMode pageinfo/tocMode; view Type pageinfo/viewType; viewerUrl docinfo/viewerUrl;5 tocMode pageinfo/tocMode; viewerUrl docinfo/viewerUrl; 6 6 rootUrl here/getDocumentViewerURL; 7 7 numPages docinfo/numPages | nothing;"> … … 29 29 pn pageinfo/pn; 30 30 flowLtr python:pageinfo.get('pageFlow','ltr')!='rtl'; 31 textPage python:here.getTextPage(mode= viewType, pn=pn, docinfo=docinfo, pageinfo=pageinfo) or '[no text here]';">31 textPage python:here.getTextPage(mode='xml', pn=pn, docinfo=docinfo, pageinfo=pageinfo) or '[no text here]';"> 32 32 <!-- header --> 33 33 <div class="page-head"> … … 67 67 <form tal:attributes="action viewerUrl" class="autosubmit"> 68 68 <input type="hidden" 69 tal:define="params python:here.getParams(params={'view Type':None})"69 tal:define="params python:here.getParams(params={'viewMode':None})" 70 70 tal:repeat="param params" 71 tal:attributes="name param; value python:params[param]" /> <input 72 class="autosubmit" type="radio" name="viewType" value="" 73 tal:attributes="checked python:viewType!='xml'" /> Text<br /> <span 74 class="optionsText" tal:condition="python:viewType!='xml'"> 75 <input type="checkbox" class="autosubmit" name="viewType" 76 value="dict" tal:attributes="checked python:viewType=='dict'" /> Dictionary<br /> 77 </span> <span class="optionsText" 78 tal:condition="python:viewType!='xml' and docinfo.get('numPlaces',0)"> 79 <input type="checkbox" class="autosubmit" name="viewType" 80 value="gis" tal:attributes="checked python:viewType=='gis'" /> Places<br /> 81 </span> <input type="radio" class="autosubmit" name="viewType" 82 tal:attributes="value string:xml; checked python:viewType=='xml'" /> XML<br /> 71 tal:attributes="name param; value python:params[param]" /> 72 <input class="autosubmit" type="radio" name="viewMode" value="text" 73 tal:attributes="checked python:viewMode=='text'" /> Text<br /> 74 <input type="radio" class="autosubmit" name="viewMode" value="text" 75 tal:attributes="checked python:viewMode=='xml'" /> XML<br /> 83 76 <input type="submit" value="Go!" /> 84 77 </form> … … 97 90 <!--"END TEXT SIZE"--> 98 91 99 <!--"BEGIN DICTIONARY OVERVIEW"-->100 <div class="options" tal:condition="python:viewType=='dict'">101 <h4>Dictionary view</h4>102 <form name="f3" action="">103 <input type="radio" name="r3" />Tab<br /> <input type="radio" name="r3" />Window<br />104 </form>105 </div>106 <!--"END DICTIONARY OVERVIEW"-->107 108 92 <!--"BEGIN TEXT NORMALIZATION"--> 109 <div class="options" tal:condition="python:view Type!='xml'">93 <div class="options" tal:condition="python:viewMode!='xml'"> 110 94 <h4>Text normalization</h4> 111 95 <form tal:attributes="action viewerUrl" class="autosubmit" … … 126 110 <!--"END TEXT NORMALIZATION"--> 127 111 128 <!--"BEGIN PLACES"-->129 <div class="options" tal:condition="python:viewType=='gis'">130 <tal:block131 tal:define="gisPlaces python:here.getGisPlaces(docinfo=docinfo, pageinfo=pageinfo); gisAllPlaces python:here.getAllGisPlaces(docinfo=docinfo, pageinfo=pageinfo);">132 <span><b>Places</b></span>133 <br />(Link to extern:)<br />134 <span>Page</span>135 <span style="float: right"> <a136 tal:attributes="href python:'http://chinagis.mpiwg-berlin.mpg.de/chinagis/REST/db/mpdl/%s?id=%s&format=%s'%(name,gisPlaces,'gis')"137 target="_blank"> <img src="images/arrow.png" alt="" />138 </a>139 </span>140 <br />141 <span>Book</span>142 <span style="float: right"> <a143 tal:attributes="href python:'http://chinagis.mpiwg-berlin.mpg.de/chinagis/REST/db/mpdl/%s?format=%s'%(name,'gis')"144 target="_blank"> <img src="images/arrow.png" alt="" />145 </a>146 </span>147 <br />148 </tal:block>149 </div>150 <!--"END PLACES"-->151 112 </div> 152 113 <!-- /col-right -->
Note: See TracChangeset
for help on using the changeset viewer.