This repository was archived by the owner on Sep 10, 2021. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,19 +40,19 @@ public function getItemViewLink($params)
4040 if ($ this ->ModuleComponent ->Main ->canVisualizeWithSliceView ($ item )) {
4141 $ webroot = Zend_Controller_Front::getInstance ()->getBaseUrl ();
4242 $ html = '<li><a href=" ' .$ webroot .'/ ' .$ this ->moduleName .'/paraview/slice?itemId= ' ;
43- $ html .= $ item ->getKey ().'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
43+ $ html .= htmlspecialchars ( $ item ->getKey (), ENT_QUOTES , ' UTF-8 ' ).'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
4444 $ html .= $ this ->moduleName .'/public/images/sliceView.png" /> Slice Visualization</a></li> ' ;
4545
4646 $ html .= '<li><a href=" ' .$ webroot .'/ ' .$ this ->moduleName .'/paraview/volume?itemId= ' ;
47- $ html .= $ item ->getKey ().'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
47+ $ html .= htmlspecialchars ( $ item ->getKey (), ENT_QUOTES , ' UTF-8 ' ).'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
4848 $ html .= $ this ->moduleName .'/public/images/volume.png" /> Volume Visualization</a></li> ' ;
4949
5050 return $ html ;
5151 } elseif ($ this ->ModuleComponent ->Main ->canVisualizeWithSurfaceView ($ item )
5252 ) {
5353 $ webroot = Zend_Controller_Front::getInstance ()->getBaseUrl ();
5454 $ html = '<li><a href=" ' .$ webroot .'/ ' .$ this ->moduleName .'/paraview/surface?itemId= ' ;
55- $ html .= $ item ->getKey ().'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
55+ $ html .= htmlspecialchars ( $ item ->getKey (), ENT_QUOTES , ' UTF-8 ' ).'"><img alt="" src=" ' .$ webroot .'/modules/ ' ;
5656 $ html .= $ this ->moduleName .'/public/images/pqUnstructuredGrid16.png" /> Surface Visualization</a></li> ' ;
5757
5858 return $ html ;
Original file line number Diff line number Diff line change @@ -43,6 +43,6 @@ $this->headScript()->appendFile($this->moduleWebroot.'/public/js/jquery/iviewer/
4343 <div class="wrapper">
4444 <div id="viewer" class="viewer"></div>
4545 </div>
46- <div id='urlImage' style="display:none;"><?php echo $ this ->imageUrl ?> </div>
46+ <div id='urlImage' style="display:none;"><?php echo $ this ->escape ( $ this -> imageUrl ); ?> </div>
4747<?php
4848echo $ this ->headScript ();
Original file line number Diff line number Diff line change @@ -42,9 +42,9 @@ $this->headScript()->appendFile($this->webroot.'/modules/visualize/public/js/wra
4242 <?php
4343 foreach ($ this ->sameLocation as $ item ) {
4444 echo "<li> " ;
45- echo "<a class='linkedcontentLink' preview=' {$ item ->preview }' element=' {$ item ->getKey (
46- )}' href=' {$ this ->webroot }/item/ {$ item ->getKey ()}'> " .$ this ->slicename (
47- $ item ->getName (),
45+ echo "<a class='linkedcontentLink' preview=' {$ item ->preview }' element=' {$ this -> escape ( $ item ->getKey (
46+ )) }' href=' {$ this ->webroot }/item/ {$ this -> escape ( $ item ->getKey () )}'> " .$ this ->slicename (
47+ $ this -> escape ( $ item ->getName () ),
4848 45
4949 )."</a> " ;
5050 echo "</li> " ;
You can’t perform that action at this time.
0 commit comments