Thursday, March 25, 2010

Permanent redirect with Apache Mod rewrite

Yesterday, I set up a permanent redirect for my personal site on baer-torsten.de to redirect all requests without leading www using Apache Mod rewrite and RewriteCondition and RewriteRule.

Here's my snippet that I'm using
RewriteCond %{HTTP_HOST} !^www\. [NC]
RewriteRule ^/(.*)$ http://www\.%{HTTP_HOST}/$1 [R=301,L]

Someone may ask why I should do that?
The simple answer: SEO

Search engines are crawling the web to indexing content of web pages. So if they discover links to www.example.com they are not seen as a reference to the same content reachable through example.com.

That's all.

Good german resource explains redirection: Automatische Weiterleitung

Friday, March 19, 2010

Consuming XML-RPC web services with C# - Part 1 - the rough way


While dealing with integration of Bugzilla as data provider within BugtraqPlugin (which I described here) I encountered that bugzilla has an XML-RPC interface. Not this bad, but

How to perform XML-RPC calls with c# and .NET?

It's a simple task to get access on soap web services because it provides a description of it's own interface through a wsdl definition, so you easily can generate proxy classes for such a case.

But whats about XML-RPC web services? Here is just a sample practiced on bugzilla web service.