post paramters are sent as request body not post parameters in ios
See original GitHub issueBug description: I want to send post parameters but by using body it will send post body not post parameters and i can send get parameters but not post parameters.
To Reproduce:
<WebView
animating
startInLoadingState
source={{
uri: 'http://192.168.43.238/test.php',
method:'POST',
body:'groupcode=test',
}}
/>
<?php
var_dump($_POST);
Expected behavior: I’d like to get post parameters with $_POST not in request body with file_get_contents(‘php://input’)
Environment:
- OS: ios
- react-native version: 59.9
- react-native-webview version: 5.8.1
Issue Analytics
- State:
- Created 4 years ago
- Comments:5
Top Results From Across the Web
Unable to post parameters in post request ios swift
I'm trying to send these parameters as ...
Read more >XMLHttpRequest.send() - Web APIs | MDN
send () accepts an optional parameter which lets you specify the request's body; this is primarily used for requests such as PUT ....
Read more >Building requests | Postman Learning Center
Your requests can send parameters, authorization details, ... Typically you will use body data with PUT , POST , and PATCH requests.
Read more >HTTP Post Requests in Swift for be… | Apple Developer Forums
I'm trying to code an app, and I'm learning pretty well on the UI side of things, mostly because swiftUI makes that excessively...
Read more >URLSession GET and POST HTTP Requests in Swift
Create A URLRequest · HTTP Request With Headers · HTTP Request With URL Parameters · POST HTTP Request With JSON Body · Create...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I’ve faced that bug too. Here is a workaround that worked for me :
headers: { 'Content-Type': 'application/x-www-form-urlencoded', }
@kegi config fix the problem