Xamarin display html5, css3, js, ajax - c#

I need display html5 document in my xamarin application, i need support for html5, css3, javascript and ajax. Is there any solution to display it?

The built in UIWebView in iOS is always quite limited in what it can do. Especially when you want a lot of fancy stuff like the technologies you mentioned. In iOS8 the WKWebView and the WebKit framework was introduced which is said to be a lot better but I have yet to work with it. I believe Xamarin Forms uses UIWebView under the hood though.

Related

Replacing Latest .NET WebBrowser Control with a browser, like Firefox or Chrome

I am using Visual Studio C# found an ActiveX control but it looks like it's an old version.
I need:
A browser that can integrate inside a window of my application (not a
separate window)
A good support for CSS, js and other web technologies, on par with
any modern browser
Basic browser functions like "navigate", "back", "reload"... Liberal
access to the page code and output.
Take a look at CefSharp: https://github.com/cefsharp/CefSharp
CefSharp lets you embed Chromium in .NET apps. It is a lightweight .NET wrapper around the Chromium Embedded Framework (CEF) by Marshall A. Greenblatt. About 30% of the bindings are written in C++/CLI with the majority of code here is C#. It can be used from C# or VB, or any other CLR language. CefSharp provides both WPF and WinForms web browser control implementations.
take a look at GeckoFx https://bitbucket.org/geckofx/. I was using it about 2 year ago and it was pretty easy to use. It's free and not "dead", meaning it is being keeped up to date.
DotNetBrowser can satisfy your needs.
This library provides Chromium-based WPF and WinForms components that can be embedded into your .NET application. The component supports HTML5, CSS, JavaScript, DOM access, DOM events and even calling JavaScript from C# and vice versa.
DotNetBrowser API also provides basic browser functions like loading URLs and HTML, reloading page, navigating back and forward, working with cookies, etc. Actually, all its functions are perfectly described in the product's Knowledge Base.
The control is commercial,but there are free academic and open-source licenses.
SharpBrowser based on cefsharp . accidentally found it while browsing the cefsharp repos
http://github.com/sharpbrowser/SharpBrowser

How do I build a mobile(tablet) friendly version of my website?

I created website and it uses fluid layout CSS for most of the parts. I now want to make a tablet friendly look of this website.
This website should be viewable properly on Ipad. That's my only requirement.
How can I do this? Which are the development tools to speed me up for this?
Edit: Many people are give suggestion to use Jquery Mobile. Can I use that with my existing Asp.Net website? Do I need to change my whole existing CSS and also am I restricted to use those Jquery UI buttons only?
2nd and most important question is will this work with Asp.Net Vanilla. Say if I have a gridview on my page. Will Jquery mobile work?
For device friendly website, you should use Asp.net MVC4 and jQuery Mobile. It has great mobile features
First you should read Using HTML5 to Create Mobile Experiences and 50 Responsive web examples
Use the CSS Media Queries. And here is a useful article about ASP.NET MVC4 mobile features.
You can also look into responsive CSS. It uses device width and image scaling and good CSS definitions to scale the site to the device.
You can also use a framework for your responsive design.
e.g. framelessgrid

Metro style apps with Html and C#

According to this slide
http://media.infragistics.com/community/general/windows8-platform-tools.jpg
Does it mean I have to use XAML view with C# if I want to develop a metro styled application?
Can I use a HTML/JS/CSS - C# combination with event handlers and all? Something like ASP.NET Webforms/MVC . I know it is not the same client server architecture, but since metro styled apps support HTML/JS, I was wondering.
I can use Win-JS. But can I rather write C# than Javascript, and use HTML rather than XAML?(I dont know XAML and I like C#)
All the C# samples I found online use XAML.
Perhaps you can write portions of your program logic in C# and package it as a library and then create a HTML5/JS app that references the C# Library. That way you should only need to use JS for the parts that are directly related to UI functions and C# for the rest.
I will point out that I haven't tried it yet, but Bill in this thread says that he got it to work.
No, you can only use XAML with C#, or HTML+CSS+JS. But XAML is great markup language, so I think you able to use it.
You can create a "WinMD" library in c# (or c++) that can be invoked from JavaScript. There are a ton of limitations that WinMD libraries have over normal .net libraries and the usage model would be would at all like ASP.NET MVC. Frankly, unless you have a lot of business logic in c# already or if you want to reuse a bunch of code in Win8 Metro apps spanning both HTML and XAML, this WinMD thing is more hassle than its worth.
According to MSDN - Dev Center - Metro style apps you can use C#/VB/C++ and XAML and JavaScript and HTML5 to develop a metro styled application (for Windows8/WindowsPhone).

Resources to create your own html 5 / css3 layout engine in C#

Are there any resources out there for how to create your own layout engine (like webkit) in C#, that supports html 5 and css 3, preferably through MSHTML, or anything else.
Also, if the above is impossible, how can I add on to the webbrowsercontrol in WinForms .NET to help it support the latest web standards.
Thanks.
You can't change MSHTML, but you can use a different control instead of the default IE based one. Webkit, you can try https://github.com/webkitdotnet (Still looks somewhat experimental though), and GeckoFX http://www.geckofx.org/ which aims to be a drop-in replacement using Gecko (Firefox layout engine).
I'm not sure if they both support all the features the normal WebBrowserControl does though.

C# html5 web browser object

I am attempting to make a web browser object in C# which support html5 as good as Safari or Chrome. My main goal is for playing video, or supporting the video tag. So far i have got WebKit.Net working and playing html5 video off w3schools website, but this only works when quicktime is installed; and i really hate that route. I read http://en.wikipedia.org/wiki/HTML5_video so i know somewhat why quick time is needed.
I am currently attempting to wrap up chromium into a C# web browser object. Do you have any suggestions on how i can accomplish creating a C# Web Browser which support html5?
You could also check out my new project: https://github.com/chillitom/CefSharp
This brings the Chromium Embedded Framework to .Net / C#. See the Github page for source, binaries and example.
Some features:
a browser control with navigation commands
INotifyPropertyChanged events
ExecuteJavascript
Register your own scheme/protocol handlers
intercept resource downloads
bind CLR objects into Chromium's JavaScript context.
It's still in the pre-alpha stages so all feedback appreciated.
If you're using WPF, you can use http://chriscavanagh.wordpress.com/2009/08/25/a-real-wpf-webbrowser/. This is a Chromium implementation for WPF.

Categories

Resources