Diese Seite mit anderen teilen ...

Informationen zum Thema:
WinDev Forum
Beiträge im Thema:
Erster Beitrag:
vor 2 Jahren
Letzter Beitrag:
vor 2 Jahren
Beteiligte Autoren:
Fabrice Harari, Binod Lohani

question on buffer and HTTPfunction

Startbeitrag von Binod Lohani am 19.06.2016 00:33

Hello gang !! I have 3 questions.

In windev 20 any sort of function like buffertostring (buffer variable) ?? Or how could i manipulate buffer variable.

Httpgetresult returns buffer or string. anyone know when it returns buffer and when it returns string ??

my_HttpRequest is httpRequest .
my_HttpRequest..content use Buffer Type. But my (PHP)webapi needs String . how to Process ??




to put a buffer in a string, just do:

of course, this will work properly ONLY if the buffer content is a string

AFAIK, httpgetresult returns a string when the httprequest was done in get mode, and a buffer when it was done in post mode

As for the 3rd question, a buffer with a string content is just a string, so put your string in your buffer, how the httprequest sends it depends of the mode you are using (get or post).

Best regards

von Fabrice Harari - am 19.06.2016 11:22
Thanks Fabrice !!
And how could I send Unicode string with HttpRequest POST method ?? When I send Ansi string everything works fine and When i pass unicode string everything goes wrong !!
Thanks Again !!

von Binod Lohani - am 19.06.2016 13:58
Hi again

I don't know what "goes wrong" means in your case. I can tell you that I'm sending unicode content in post mode all the time and there is nothing special to do... (in wxreplication, by example)

of course, it will work ONLY if the webservice receiving your call is actually WAITING for unicode content.

I cannot tell you more than that without seeing your code and reading the specs of the webservice

Best regards

von Fabrice Harari - am 20.06.2016 12:21
Zur Information:
MySnip.de hat keinen Einfluss auf die Inhalte der Beiträge. Bitte kontaktieren Sie den Administrator des Forums bei Problemen oder Löschforderungen über die Kontaktseite.
Falls die Kontaktaufnahme mit dem Administrator des Forums fehlschlägt, kontaktieren Sie uns bitte über die in unserem Impressum angegebenen Daten.