« iOS SDK and MBS Works… | Home | FileMaker Magazin - M… »

Cookies in HTMLViewer


If you use HTMLViewer in your Xojo desktop app, you may need to handle cookies from time to time. The MBS Plugins have various classes to work with cookies, e.g. to read them for storing a database. And later you can restore them to make sure your users can use auto login features in the webviewer.

On Windows we have a couple of classes for use with WebKit/Chromium. This includes the ChromiumCookieManagerMBS class and the ChromiumCookieMBS class. With AllCookies method you can query all current cookies, save them for later and on the next run add them with SetCookie method.

When using a Mac, you can use the Cocoa classes for cookie management: NSHTTPCookieStorageMBS and NSHTTPCookieMBS class.

The classes for Linux with WebKit look similar: LinuxWebCookieStoreMBS and LinuxWebCookieMBS

As all those classes use WebKit cross platform, they have nearly the same functionality.
Check also other functions like running javascript, extracting text or html from webpages or rendering a picture from website.
18 02 16 - 14:53
No comments

  
Remember personal info?

Emoticons / Textile


Notify:
Hide email:

Small print: All html tags except <b> and <i> will be removed from your comment. You can make links by just typing the url or mail-address.