Simple XML Parse Flickr Feed
So in one of my recent projects I had to parse a Flickr feed and extract the image urls the code I came up with is as follows:
<?php
/* Author: Samuel Haddad
* SimpleXML Flicker Feed Parser
*/
//Feed URL in RSS Format
$url ="http://api.flickr.com/services/feeds/photos_public.gne?lang=en-us&format=rss_200"; //FEED URL
//Use simple XML to parse the feed
$xml = simplexml_load_file($url);
$items = $xml->xpath('/rss/channel/item');
foreach($items as $item){
$nsmedia = $item->children('http://search.yahoo.com/mrss/');
$img = $nsmedia->content->attributes();
echo $img; //URL of Image
echo "<br/>";
}
?>Of course my code did more then just extract the URL, but I will leave the rest up to the creative developers.
AnkhSVN and Google Code
Recently I was trying to commit to my Jango Desktop project hosted on Google code. I was using AnkhSVN and I kept getting an error similar to:
SharpSvn.SvnRepositoryIOException: Commit failed (details follow): ---> SharpSvn.SvnRepositoryIOException: Server sent unexpected return value (405 Method Not Allowed) in response to MKACTIVITY request for
If anyone else runs into this issue I was trying to commit to the read only repository. An easy way to tell if this is your issue is to look at the repository url. Google’s commit repository starts with https: // not http://
If this is your issue log into Google code to obtain the correct repository url.
Prish Image Resizer
There are many Windows 7 Image resizers out there that integerate into the shell, but this is my favorite.
http://prishcom.spaces.live.com/blog/cns!6A6A204ABDF15411!128.entry
Bypass Symantec Endpoint Protection
So recently I had bypass Symantec endpoint protection. Instead of having to stop services and delete registry keys like my other Trend Micro Post it is worth trying the default password of Symantec which worked for me.
Uninstall TrendMicro OfficeScan
This procedure work as of June 5th 2010
The problem:
When trying to uninstall TrendMico Office Scan you are prompted for a password.
Solution:
- Start -> run and type MSCONFIG
- Under services and uncheck TrendMicro Unauthorized Change Prevention Service
- Restart the computer
- Start -> run type Regedit
- Navigate to HKEY_LOCAL_MACHINE\SOFTWARE\TrendMicro\PC-cillinNTCorp\CurrentVersion\Misc
- Changing the AllowUninstall value to 1