I'm calling a php script from an asp page. The problem is that the php script called in this way cannot set the cookie. Here are the 2 scripts:
<% Dim objXMLHTTP Set objXMLHTTP = Server.CreateObject("Msxml2.ServerXMLHTTP.6.0") objXMLHTTP.Open "POST", "http://127.0.0.1/setcookie.php", False objXMLHTTP.Send if len(objXMLHTTP.responseText)>0 then response.write "Result: "&objXMLHTTP.responseText Set objXMLHTTP = Nothing %>
<?php setcookie('mycookie', '12345', time() + (86400 * 30), "/"); echo 'ok'; ?>
The two pages run under the same website, in the same folder. I tried with both "POST" and "GET" with no success. If I run the php directly, cookie is created.
Any advice? Thanks