3 Replies Latest reply on Mar 2, 2010 9:56 PM by Moore6931

    MM_callJS Does Not Respond

    Moore6931 Level 1

      In setting up a webpage to display my photographs and Mechanical Engineering, my thought is to use Tabbed Panels to select the gallery (roses, Big Sur Coast, Pacific Grove, etc.) for viewing, then display thumbnails in the Content Panel.  All of the photographs are listed in a master list.  A variable "myselector" would be used to filter the master list for the selected gallery.  When selecting the tab, then "myselector would be defined and the list filtered.  I tried Behaviors (onclick and onfocus) with callJS for the tab; the javascript was either a function or entering the javascript to define "myselector".  I have not be able to have the javascript run.  With popup messages, I verified that the onclick, onfocus or mouseover was functioning.

       

      For diagnosis, I made a test file to define the text variable, only, and write the text variable value.  Again, the javascript does not respond.  Please tell me what error this operator is making.  The script for the test file is included.

       

      I thank you.

       

       

      <script type="text/javascript">
      <!--
      function MM_callJS(jsStr) { //v2.0
        return eval(jsStr)
      }
      //-->
      </script>
      <script type="text/javascript">
      var testvar;
      function testfunc(){testvar="1234567890"};
      </script>
      </head>
      <body>
      <p ondblclick="MM_callJS('testvar=\&quot;1234567890\&quot;')"> Push this </p> <p onclick="MM_callJS('function testfunc()')">button.</p>
      <p> </p>
      <p> </p>
      <script type="text/javascript">
      var testvar;
      </script>
      <script type="text/javascript">
      function testfunc() {testvar="1234567890"};
      </script>
      
      <script type="text/javascript"> 
      document.write (testvar);
      </script>