<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Andreas Hassellöf &#187; Technology</title>
	<atom:link href="http://hassellof.com/category/technology/feed" rel="self" type="application/rss+xml" />
	<link>http://hassellof.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Sun, 29 Nov 2009 19:08:22 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Installer encountered an error: 0&#215;80070422</title>
		<link>http://hassellof.com/2009/02/installer-encountered-an-error-0x80070422.html</link>
		<comments>http://hassellof.com/2009/02/installer-encountered-an-error-0x80070422.html#comments</comments>
		<pubDate>Thu, 26 Feb 2009 12:59:01 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Technology]]></category>
		<category><![CDATA[windows microsoft]]></category>

		<guid isPermaLink="false">http://www.evolve.se/?p=96</guid>
		<description><![CDATA[There are times when it becomes painfully obvious just Why I Avoid Windows as much as possible&#8230;
Today I downloaded the Windows Media Streaming Server package for Windows 2008 Server x64 from Microsoft, and when I tried to install it I got the following pretty, intuitive and self-explanatory error message:

Installer encountered an error: 0&#215;80070422
The service cannot [...]


No related posts.

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>There are times when it becomes painfully obvious just <strong>Why I Avoid Windows</strong> as much as possible&#8230;</p>
<p>Today I downloaded the Windows Media Streaming Server package for Windows 2008 Server x64 from Microsoft, and when I tried to install it I got the following pretty, intuitive and self-explanatory error message:</p>
<p><a href="http://hassellof.com/wp-content/uploads/2009/02/windows-error1.jpg"><img class="size-medium wp-image-99 alignnone" title="The service cannot be started, either because it is disabled or because it has no enabled devices associated with it." src="http://www.evolve.se/wp-content/uploads/2009/02/windows-error-300x129.jpg" alt="windows error 300x129 Installer encountered an error: 0x80070422" width="300" height="129" /></a></p>
<blockquote><p>Installer encountered an error: 0&#215;80070422<br />
The service cannot be started, either because it is disabled or because it has no enabled devices associated with it.</p></blockquote>
<p>What this actually means is &#8220;This software package requires that the <strong>Windows Update Service</strong> and that <strong>BITS</strong> (Background Intelligent Transfer Service) are running during installation&#8221;.</p>
<p>Now, granted, it was not all that difficult to find this answer on Google. But really, wouldn&#8217;t it be much easier just to have more descriptive error messages to begin with?</p>
<p>Oh well. In a perfect world perhaps.</p>


<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://hassellof.com/2009/02/installer-encountered-an-error-0x80070422.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Updated: RSS Autodiscovery with PHP</title>
		<link>http://hassellof.com/2008/04/updated-rss-autodiscovery-with-php.html</link>
		<comments>http://hassellof.com/2008/04/updated-rss-autodiscovery-with-php.html#comments</comments>
		<pubDate>Fri, 04 Apr 2008 19:09:08 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://www.evolve.se/?p=12</guid>
		<description><![CDATA[Found an excellent function made by Keith Devens for autodiscovery of RSS feeds on a website.
The only issue I had with it was that a lot of news sites these days publish more than one RSS feed, so I updated the code to return an array of feeds instead of only the first one + [...]


No related posts.

Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.]]></description>
			<content:encoded><![CDATA[<p>Found an excellent function made by <a href="http://keithdevens.com/weblog/archive/2002/Jun/03/RSSAuto-DiscoveryPHP">Keith Devens</a> for autodiscovery of RSS feeds on a website.</p>
<p>The only issue I had with it was that a lot of news sites these days publish more than one RSS feed, so I updated the code to return an array of feeds instead of only the first one + I made it fetch the body of the page instead of supplying it in the call.</p>
<p>This is what I got:</p>
<p><code><br />
function getRSSLocation($location = false){</code></p>
<p><code>$html = file_get_contents($location);<br />
$feeds = array();</p>
<p></code></p>
<p><code> if(!$html or !$location){<br />
return false;<br />
}else{<br />
#search through the HTML, save all  tags<br />
# and store each link's attributes in an associative array<br />
preg_match_all('/ /si', $html, $matches);<br />
$links = $matches[1];<br />
$final_links = array();<br />
$link_count = count($links);<br />
for($n=0; $n&lt;$link_count; $n++){<br />
$attributes = preg_split('/\s+/s', $links[$n]);<br />
foreach($attributes as $attribute){<br />
$att = preg_split('/\s*=\s*/s', $attribute, 2);<br />
if(isset($att[1])){<br />
$att[1] = preg_replace('/([\'"]?)(.*)\1/', '$2', $att[1]);<br />
$final_link[strtolower($att[0])] = $att[1];<br />
}<br />
}<br />
$final_links[$n] = $final_link;<br />
}<br />
#now figure out which one points to the RSS file<br />
for($n=0; $n&lt;$link_count; $n++){<br />
if(strtolower($final_links[$n]['rel']) == 'alternate'){<br />
if(strtolower($final_links[$n]['type']) == 'application/rss+xml'){<br />
$href = $final_links[$n]['href'];<br />
}<br />
if(!$href and strtolower($final_links[$n]['type']) == 'text/xml'){<br />
#kludge to make the first version of this still work<br />
$href = $final_links[$n]['href'];<br />
}<br />
if($href){<br />
if(strstr($href, "http://") !== false){ #if it's absolute<br />
$full_url = $href;<br />
}else{ #otherwise, 'absolutize' it<br />
$url_parts = parse_url($location);<br />
#only made it work for http:// links. Any problem with this?<br />
$full_url = "http://$url_parts[host]";<br />
if(isset($url_parts['port'])){<br />
$full_url .= ":$url_parts[port]";<br />
}<br />
if($href{0} != '/'){ #it's a relative link on the domain<br />
$full_url .= dirname($url_parts['path']);<br />
if(substr($full_url, -1) != '/'){<br />
#if the last character isn't a '/', add it<br />
$full_url .= '/';<br />
}<br />
}<br />
$full_url .= $href;<br />
}<br />
if(!in_array($full_url, $feeds))<br />
$feeds[] = $full_url;<br />
}<br />
}<br />
}<br />
return $feeds;<br />
}<br />
}<br />
</code></p>


<p>No related posts.</p>
<p>Related posts brought to you by <a href='http://mitcho.com/code/yarpp/'>Yet Another Related Posts Plugin</a>.</p>]]></content:encoded>
			<wfw:commentRss>http://hassellof.com/2008/04/updated-rss-autodiscovery-with-php.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
