Hi, Craig. I am in the process of adding a feature to the Denon AVP/AVR
plugin that requires adding some Javascript code to the setup menu the
plugin uses to customize settings for each player. The menu works fine
under the LMS Settings menu. However, when using it with Material Skin,
an error is thrown in the debug log indicating that the JS function
specified to be invoked when a pulldown menu selection is changed can't
be found. Here is the line referencing the function: 
Code:
--------------------
    <select name="[% pw.pref_prefix %]quickSelect" 
onchange='checkSelect(this.value);' >
--------------------

and here is the message from Material's debug log:


Code:
--------------------
    basic.html?player=b8:26:eb:c1:71:f0:1 Uncaught ReferenceError: checkSelect 
is not defined
  at HTMLSelectElement.onchange (basic.html?player=b8:26:eb:c1:71:f0:1:1)
  onchange @ basic.html?player=b8:26:eb:c1:71:f0:1
--------------------


And here is the JS function definition:

Code:
--------------------
                                <script type="text/javascript">
                                        function checkSelect(val) {
                                                var 
element=document.getElementById('inputSource');
                                                if(val=='0')
                                                        
element.style.display='inline';
                                                else  
                                                        
element.style.display='none';
                                        }
                                </script>       
  
--------------------


&#65279;As mentioned, it functions as designed with the LMS Settings
menu. Is there something I can do to get it working with Material Skin?
I admittedly know very little about HTML or JS so I apologize if this is
something obvious.



Sam
------------------------------------------------------------------------
SamY's Profile: http://forums.slimdevices.com/member.php?userid=63495
View this thread: http://forums.slimdevices.com/showthread.php?t=109624

_______________________________________________
plugins mailing list
plugins@lists.slimdevices.com
http://lists.slimdevices.com/mailman/listinfo/plugins

Reply via email to