Jump to content

send JS value to delphi ... Uncaught SyntaxError


erich.wanker

Recommended Posts

Hi .. 🙂

what is wrong with this code (embeeded  in UniHTMLFrame) -> servermodule -options - soControlNameAsID = true

.. i cant find the problem 😉 

<script>
var theInput = document.getElementById("kb_selected_color");
var theColor = theInput.value;

theInput.addEventListener("input", to_delphi, false);

function to_delphi()
{
ajaxRequest(f_color.form,''Farbe'' , [''param0='+theInput.value+''']);                     <-----------------HERE is the problem
}


</script>

Link to comment
Share on other sites

8 hours ago, erich.wanker said:

Hi .. 🙂

what is wrong with this code (embeeded  in UniHTMLFrame) -> servermodule -options - soControlNameAsID = true

.. i cant find the problem 😉 

<script>
var theInput = document.getElementById("kb_selected_color");
var theColor = theInput.value;

theInput.addEventListener("input", to_delphi, false);

function to_delphi()
{
ajaxRequest(f_color.form,''Farbe'' , [''param0='+theInput.value+''']);                     <-----------------HERE is the problem
}


</script>

Hello

Try to create ajaxRequest like the below code

theInput = document.getElementById("O14_id-inputEl");
ajaxRequest(UniLoginForm1.form, "Farbe", {param0: theInput.value })

 

  • Thanks 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...