A
A
ant1vit2017-09-13 14:17:26
JavaScript
ant1vit, 2017-09-13 14:17:26

Passing data by POST method without using Form?

There is a list on the site.ru/page page:

<a  id-category="1" href="site.ru/page2">Блок 1</a>
....
<a  id-category="20" href="site.ru/page2">Блок 20</a>

It is necessary that by clicking on the link there would be a transition to site.ru/page2 with POST data, for their further insertion. For example, an inscription appears on the page page - you clicked on the button with id-category - 1
Where to dig? how to implement?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrey Perov, 2017-09-13
@SnaIP

https://api.jquery.com/jquery.post/
collect data on a click event
and transfer it to data there, if necessary on a clean one https://www.w3schools.com/xml/ajax_xmlhttprequest_...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question