LevendFW

Last year Levend started the open source project LevendFW under my techincal lead. This is a framework that offers a web interface for asp.net application development. Free for all to download, use and extend.

We are still building the the major features, but there is code submitted already. Soon we will publish the first modules for this framework.

We are looking for developers and designers to contribute to the project. Please get intouch when you like join the project.

Nerd nor trendy, but having good ideas? Don't hesitate and tell us! 

project details

Resumé

I got my bachelor's degree in engineering in 2003. After working as a project engineer at a company that sells electrotechnical systems I started as a freelance software developer.

As a freelancer I worked at small and bigger (international) companies.

In 2009 I started together with Jeroen Rozeboom "Levend", a website and software company.

My LinkedIn Profile

 

Jan 17

Written by: Willem de Jong
1/17/2010 4:20 PM 

For an application I am working on, I needed to integrate dynamic content from a webpage. Unfortunately the website doesn’t offer any kind of xml feed, so I needed to transform the xhtml from the webpage into a format for my application.

My first idea was to look at the xhtml as if it is xml, which could be a solution. Because I am convinced that there is always somebody else with the same problem or part of problem, I was searching the web for blog articles and forum posts for information about this.

While searching I found HtmlAgilityPack. HtmlAgilityPack is an open source library for the dotnet framework and makes it very easy to get html pages from an URL and search for content in that page. By using xpath, HtmlAgilityPack returns a Node or a Nodelist from which you can extract the inner text, inner html and all attributes. This is basically all you need to convert an (x)html page into something your application understands.

You can use it like this:

//Create the object and get the page
HtmlWeb hw = new HtmlWeb();
HtmlDocument doc = hw.Load(Url);

//Use Xpath to get a node
HtmlNodeExampleNode = doc.DocumentNode.SelectSingleNode("//div[@id='FinalResult']");

//Get the content from the node
string innerHtml = ExampleNode.InnerHtml;
string innerText = ExampleNode.InnerText;
string attribute = ExampleNode.Attributes["order"].Value;

Tags:

Your name:
Your website:
Comment:
Security Code
Enter the code shown above in the box below
Add Comment   Cancel 

Favorites