Jump to content

Joe Sansalone

Members
  • Content Count

    92
  • Joined

  • Last visited

Community Reputation

5 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thank you for the code. I realize that I was doing a quick "custom" version just for text and utf8. (and boundary was the same string always coming from SendGrid). It was my attempt to get something working (my application simply needed some Form-data fields coming in). We are lucky to have you in this forum! I'll try out your code. Thanks.
  2. I'm simply doing a aRequestInfo.PostStream.Position := 0; StringList.LoadFromStream(aRequestInfo.POstStream, TEncoding.UTF8); to get the content into a string list. Then, I'll be looping through each line of the stringlist looking for Content-Disposition: form-data; name="xxx" and getting the NAME of the parameter (i.e. xxx). Then skipping a line and taking every line until --XYzZY, to get the VALUE of the name parameter. I think it will work for anything without attachments.
  3. Hi, I have a Indy HTTP server application. Currently receiving requests in the format: application/x-www-form-urlencoded. (everything works fine, I use the parsed params). I'm now also receiving Posts from SendGrid: "the post will be multipart/form-data with the email content URL encoded, but the attachments will be in multipart/form-data". Using the TIdHTTPRequestInfo.PostStream, I'm able to view the payload that they are sending me. 1. Do I need to URLDecode the email content or is it already decoded? 2. Are there any functions/classes to help parse the form-data? it looks like this: --XYzZY Content-Disposition: form-data; name="from" Joe S. <joes1234@gmail.com> --XYzZY Content-Disposition: form-data; name="text" Hello, I'm testing this email. Joe --XYzZY Content-Disposition: form-data; name="to" mb12345@parsetest.projectone.ca --XYzZY Content-Disposition: form-data; name="subject" Subject123
  4. Joe Sansalone

    trying to POST multiple values of same parameter

    OK, I got it to work via: tempBody := 'Param1=' + value1 + '&' + 'Param2=' + value2 + '&' ... etc; // build the parameters with & in-between each parameter RestRequest.Params.AddItem('Body1234', tempBody, pkREQUESTBODY, [poDoNotEncode]); // notice that there needs to be a unique name even for the entire body of parameters.
  5. Joe Sansalone

    trying to POST multiple values of same parameter

    I understand. BUT, I need: MediaUrl=value1&MediaUrl=value2&MediaUrl=value3 same parameter multiple times.
  6. Joe Sansalone

    trying to POST multiple values of same parameter

    I tried and it's not working. Is there a way to output the HTTP request text? The actual text that is being sent for the whole request?
  7. Joe Sansalone

    trying to POST multiple values of same parameter

    ok, I'll try the parameterless AddItem function ... thanks.
  8. Joe Sansalone

    trying to POST multiple values of same parameter

    The server is expecting same name parameter multiple times. But the TRestRequest.Params don't support adding the same parameter name again.
  9. I'm trying to add the same parameter name multiple times with different values (using POST). It seems like separating values via semi-colon ; and using poFlatArray only works for a GET request. FRestRequest.Params.AddItem('MediaUrl', values , TRestRequestParameterKind.pkGETorPOST, [poFlatArray]); Simply doing multiple AddItem erases previous entry if the parameter name is the same. So, How do I add the same parameter multiple times?
  10. Joe Sansalone

    multiple developer (iOS) accounts

    What's easier? Same Apple ID but developer access on 2 different App Store accounts? Or different Apple IDs - 1 for each different account?
  11. Joe Sansalone

    multiple developer (iOS) accounts

    ok great thanks!
  12. Joe Sansalone

    multiple developer (iOS) accounts

    Hi, I'll be developing an app with a different developer account in the same Delphi IDE. Does Delphi support multiple iOS developer accounts? I want to be sure before I try ... Joe
  13. Joe Sansalone

    IBX & FireDAC, Change Views

    Ok, I'll try this out.
  14. Joe Sansalone

    IBX & FireDAC, Change Views

    Thanks Sriram.
  15. Joe Sansalone

    IBX & FireDAC, Change Views

    Hi, If I set a subscription active in a transaction and then execute "Select * from Table1", how do I check if a field has been updated, or row has been deleted or inserted (other than using IS Updated, or IS Inserted in the SQL). Is it a new property of TDataSet or TField?? Joe
×