[mythtv] Mythweb Javascript issues

Steve Campbell orcusmaximus at gmail.com
Tue May 9 19:07:10 UTC 2017


Hi all,

After upgrading to the latest MythTV dist, I'm getting Javascript issues
due to the age of the jquery & prototype libraries.

The fix is to grab the latest versions from googleapis.com, and moving the
recommend definitions up a bit. Eg by applying the following diff to
modules/_shared/tmpl/default/header.php -

89a90,99
>     <script type="text/javascript">
>         <!--
>         //
-----------------------------------------------------------------------------
>         // - Setup variables for use with the recommend engines
>         //
-----------------------------------------------------------------------------
>         var recommend_enabled   = "<?php echo
setting('recommend_enabled', null); ?>";
>         var recommend_server    = "<?php echo setting('recommend_server',
null); ?>";
>         var recommend_key       = "<?php echo setting('recommend_key',
null); ?>";
>         // -->
>     </script>
91d100
<     <script type="text/javascript" src="js/prototype.js"></script>
92a102,103
>       <!--
>       <script type="text/javascript" src="js/prototype.js"></script>
93a105,108
>       -->
>       <script src="
https://ajax.googleapis.com/ajax/libs/prototype/1.7.3.0/prototype.js
"></script>
>       <script src="
https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
>
102,112d116
<
<     <script type="text/javascript">
<         <!--
<         //
-----------------------------------------------------------------------------
<         // - Setup variables for use with the recommend engines
<         //
-----------------------------------------------------------------------------
<         var recommend_enabled   = <?php echo setting('recommend_enabled',
null); ?>;
<         var recommend_server    = "<?php echo setting('recommend_server',
null); ?>";
<         var recommend_key       = "<?php echo setting('recommend_key',
null); ?>";
<         // -->
<     </script>


Steve
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-dev/attachments/20170509/b578599f/attachment.html>


More information about the mythtv-dev mailing list