This repository was archived by the owner on Sep 10, 2021. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +7
-7
lines changed Expand file tree Collapse file tree 3 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -40,19 +40,19 @@ public function getItemViewLink($params)
40
40
if ($ this ->ModuleComponent ->Main ->canVisualizeWithSliceView ($ item )) {
41
41
$ webroot = Zend_Controller_Front::getInstance ()->getBaseUrl ();
42
42
$ 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/ ' ;
44
44
$ html .= $ this ->moduleName .'/public/images/sliceView.png" /> Slice Visualization</a></li> ' ;
45
45
46
46
$ 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/ ' ;
48
48
$ html .= $ this ->moduleName .'/public/images/volume.png" /> Volume Visualization</a></li> ' ;
49
49
50
50
return $ html ;
51
51
} elseif ($ this ->ModuleComponent ->Main ->canVisualizeWithSurfaceView ($ item )
52
52
) {
53
53
$ webroot = Zend_Controller_Front::getInstance ()->getBaseUrl ();
54
54
$ 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/ ' ;
56
56
$ html .= $ this ->moduleName .'/public/images/pqUnstructuredGrid16.png" /> Surface Visualization</a></li> ' ;
57
57
58
58
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/
43
43
<div class="wrapper">
44
44
<div id="viewer" class="viewer"></div>
45
45
</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>
47
47
<?php
48
48
echo $ 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
42
42
<?php
43
43
foreach ($ this ->sameLocation as $ item ) {
44
44
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 () ),
48
48
45
49
49
)."</a> " ;
50
50
echo "</li> " ;
You can’t perform that action at this time.
0 commit comments