0

I need to use the value of a JavaScript variable in a module.
For example, I am getting a city = 'delhi' in a JavaScript file, and I need to use this value in a module showing a form.

0

1 Answer 1

0

You could send that value to a callback function in your .module file using AJAX, an example to do that stuff in forms see that tutorial Ajaxify form fields

And you could send any value to js variable see sending-a-javascript-variable-to-drupal

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.