Snippets tagged “post”
22 snippets use this tag.
- Check if $_POST existsPHP
To check if the $_POST superglobal variable exists in PHP, you can use the isset() function.
- Curl and PHP - how can I pass a json through curl by PUT,POST,GETPHP
To pass a JSON object through cURL using the PUT method, you can use the following command:
- curl POST format for CURLOPT_POSTFIELDSPHP
To make a POST request with PHP's cURL functions, you can use the CURLOPT_POST option to send POST data.
- curl posting with header application/x-www-form-urlencodedPHP
To make a POST request using curl and include a header of Content-Type: application/x-www-form-urlencoded, you can use the following command:
- Detecting request type in PHP (GET, POST, PUT or DELETE)PHP
In PHP, you can use the $_SERVER['REQUEST_METHOD'] superglobal to detect the request type.
- How do I print all POST results when a form is submitted?PHP
To print all the POST results when a form is submitted with PHP, you can use the print_r($_POST) function.
- How to call a php script/function on a html button click?PHP
To call a PHP script or function on a HTML button click, you can use JavaScript to send an HTTP request to the server when the button is clicked.
- How to Create a jQuery Ajax Post with PHPPHP
Here, we will share with you how to create a jQuery Ajax post request with PHP. Just check out the examples and choose the one that suits your needs best.
- How to include Authorization header in cURL POST HTTP Request in PHP?PHP
To include the Authorization header in a cURL POST request in PHP, you can use the CURLOPT_HTTPHEADER option and pass it an array of headers like this:
- How to POST JSON data with Python Requests?Python
You can use the requests library in Python to send a POST request with JSON data.
- How to run a PHP function from an HTML form?PHP
To run a PHP function from an HTML form, you will need to create an HTML form with the desired inputs, such as text fields and submit buttons.
- HTML/PHP - Form - Input as arrayPHP
To create an HTML form that submits an array as a form parameter, you can use the name attribute of the input element and give it a value in the form of an array.
- Java - sending HTTP parameters via POST method easilyJava
To send HTTP parameters via the POST method in Java, you can use the java.net.URL and java.net.HttpURLConnection classes. Here is an example of how you can do this:
- Laravel csrf token mismatch for ajax POST RequestPHP
The csrf_token error you are encountering occurs when you are making a POST request to your Laravel application and you have not included a valid CSRF token in the request.
- Passing multiple variables to another page in urlPHP
There are several ways to pass variables from one PHP page to another.
- PHP code to get selected text of a combo boxPHP
To get the selected text of a combo box (also known as a dropdown menu or select box) in PHP, you can use the following code:
- posting hidden valuePHP
In PHP, you can post a hidden value by including it in a hidden input field within a HTML form.
- Send value of submit button when form gets postedPHP
In PHP, you can access the value of a submit button when a form is posted in the following way:
- Sending HTTP POST Request In JavaJava
To send an HTTP POST request in Java, you can use the java.net.URL and java.net.HttpURLConnection classes. Here is an example of how you can use these classes to send a POST request:
- Setting POST variable without using formPHP
To set the value of a POST variable in PHP, you can use the following code:
- Simple PHP calculatorPHP
Sure!
- Submit html table data with via form (post)PHP
Here is an example of how to submit an HTML table data via a form (using the POST method) using PHP: