title: Scala Lift how to run javascript function and store return value in variable
body: <p>Now I have this code:</p>
  
  <pre><code>JsCmds.JsCrVar(nombreAlumnoActual, JE.Call("retornarNombre"))
  </code></pre>
  
  <p><code>nombreAlumnoActual</code> is a string var defined in my snippet and <code>retornarNombre</code> is the name of my javascript function, which is this one:</p>
  
  <pre><code>&lt;script type="javascript"&gt;
  
              function retornarNombre(){
                 return document.getElementById("nombre").value.toString();
                }
   &lt;/script&gt;
  </code></pre>
  
  <p>But when I debug my variable <code>nombreAlumnoActual</code> is <code>""</code>.</p>
  
  <p>Can someone help me?</p>