• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Question $_POST and $_GET not always available

Koen Verbruggen

Basic Pleskian
Dear Plesk gurus,

Given the following hypothetical setup in page.php
Code:
<form action="page.php?id=3">
 <input type="text" name="somevar" value="hello" />
</form>

I would expect to reload page.php with:
$_GET['id'] en $_POST['somevar'] being set
However I only receive $_GET['id'].
I used to get them both on another server (apache only).

I bypassed this by providing the id var in $_POST but then something else happens:
seems $_POST vars are only provided when I submit to the full URL:
action="https://example.com/page.php"
and are not available when using:
action="page.php" (however page.php is loaded but not with $_POST).


What am I missing here?
Hope one of you understands what's happening.

Regards.

(PHP version 5.6.32, default Plesk Nginx and Apache settings)
 
Back
Top