with the function "LoadFromFile" I load data from the server into a memo.
memo1.Lines.LoadFromFile(HostWebDir + 'webdata.ini'); work
If I now want to save a memo1 on the server with "SaveToFile", this does not work.
It comes the Save query. But the file is then on my PC under download and not on the server under the specified directory.
memo1.Lines.SaveToFile(HostWebDir + 'webdata.ini'); not work
Make this with a "TWebHttpRequest" this not work.
In can read files with Get from the server, but cannot load files with Post to the server.
(The error 405 appears)
whtwebdata.ResponseType := rtText;
whtwebdata.Command := httpGET;
whtwebdata.URL := HostWebDir + 'webdata.ini';
whtwebdata.execute; --> data via whtwebdataRequestResponse work
whtwebdata.ResponseType := rtText;
whtwebdata.Command := httpPost;
whtwebdata.PostData :='Teststring';
whtwebdata.URL := HostWebDir + 'webdata.ini';
whtwebdata.execute; not work
Get and Post-Headers is set to (default)
Cache-Control=no-cache, no-store, must-revalidate
Therefore my question, how can I post/save a simple text file on the server.
Or, what do I have to change where to make it work.
I didn't find anything in the examples.