File tree Expand file tree Collapse file tree 3 files changed +3
-1
lines changed Expand file tree Collapse file tree 3 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ public function run(Router &$router) {
2525 throw new UnspecifiedViewException ();
2626 }
2727 $ model = new LegalModel ();
28+ $ model ->license = file_get_contents ("../LICENSE.txt " );
2829 $ model ->user_session = UserSession::load ($ router );
2930 ob_start ();
3031 $ view ->render ($ model );
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ class Legal extends Model {
1010
1111 public function __construct () {
1212 parent ::__construct ();
13+ $ this ->license = null ;
1314 $ this ->user_session = null ;
1415 }
1516
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ require("./header.inc.phtml");
6060 <section>
6161 <p>For a plaintext version of the document below, <a href="<?php echo Common::relativeUrlToAbsolute ("/legal.txt " ); ?> ">click here</a>.</p>
6262 <p><pre><code><?php
63- echo htmlentities (file_get_contents ( " ../../LICENSE.txt " ) , ENT_HTML5 , "UTF-8 " );
63+ echo htmlentities ($ this -> getContext ()-> license , ENT_HTML5 , "UTF-8 " );
6464 ?> </code></pre></p>
6565 </section>
6666 </article>
You can’t perform that action at this time.
0 commit comments