0

I'm using bash to try to send a CURL to submit a form and running into issues and I believe it has to do with the special characters in some of the data.

Instead of putting the strings right into the curl command, I set variables ahead of time to hopefully avoid the issue. I know the variables work because I use them before this part with form tokens on a different call. I am still getting invalid responses back though with this particular part. Here is an example of what I am trying to send.

lang="en"
date="UTC-11:00 - Pacific/Midway - 31 Aug 2019, 16:34"
tz="Pacific/Midway"

curl -vv POST -F "lang=${lang}&tz_date=${date}&tz=${tz}" https://example.com/board/ucp.php?mode=register

Any suggestions?

Atomiklan
  • 5,164
  • 11
  • 40
  • 62
  • Possible duplicate of [Using curl to upload POST data with files](https://stackoverflow.com/questions/12667797/using-curl-to-upload-post-data-with-files) – oguz ismail Sep 01 '19 at 04:19

1 Answers1

1

Maybe. I guess you need to split the variable settings like described here

olir
  • 66
  • 5