RTC Forums

Subscription => Support => Topic started by: colutti on September 28, 2010, 07:05:08 PM



Title: Base64
Post by: colutti on September 28, 2010, 07:05:08 PM
Hello

How do i configure the Response header ContentTransferEncoding to base64?

TRtcDataServer(Sender).Response.????? := 'base64'


Title: Re: Base64
Post by: D.Tkalcec (RTC) on September 28, 2010, 07:12:40 PM
There are no automatic base64 encoders nor decoders when receiving and sending raw content using the TRtcDataProvider component. What you get from the Read method is raw data (no transformations applied) and what you send out is also raw content. How you encode or decode the data when using the TRtcDataProvider component is entirely is up to you. Only if you use TRtcClientModule/TRtcServerModule (remote functions) will encoding be handled automatically by the RTC components.

Best Regards,
Danijel Tkalcec


Title: Re: Base64
Post by: D.Tkalcec (RTC) on September 28, 2010, 07:24:09 PM
By the way ... if the Client requires this, you will also need to set ...

TRtcDataServer(Sender).Response['Content-Transfer-Encoding']:='base64';

Please note that this will not make RTC SDK do the encoding for you automatically. You still need to encode the data manually before you send it out.

Best Regards,
Danijel Tkalcec


Title: Re: Base64
Post by: colutti on September 28, 2010, 09:39:46 PM
TRtcDataServer(Sender).Response['Content-Transfer-Encoding']:='base64'

OK .. that is what i was looking for. I know I have to encode it myself.
Thanks.

 
By the way ... if the Client requires this, you will also need to set ...

TRtcDataServer(Sender).Response['Content-Transfer-Encoding']:='base64';

Please note that this will not make RTC SDK do the encoding for you automatically. You still need to encode the data manually before you send it out.

Best Regards,
Danijel Tkalcec