i want to set php session value from javascript i know it is not possible to do from javascript so i made this code
javascript:
window.open("test.php?s=1");
php:
session_start();
if(!empty($_GET['s'])) {
$_SESSION['test']= $_GET['s'];
}
it is working and all but only problem is that it opens new window and user have to close it
is it possible to do something like that without opening new window? i know it is possible to do with xmlhttp.open but it didn't really worked for me + i have no idea how to use it, tried to understand it by searching info in google but couldn't so i figured out that this way i am doing is the simples for me just need to do it without opening new window