How to protect php script from the substitution information via source code? That is, I have this button:
<a href="#" onclick="like('1'); return false;">like</a>
where 1 is the id of the news. On the server side check for the presence of such news, if there is no news echo 'error'; But here there was a following problem: when using chrome to replace the "Examine element" (Cntrl + Shift+ I) to non-existent ID, it first passes the query on ID 1, then to tampered with, that is run 2 queries.