Tuesday, 25 November 2008 11:19
Eddy
This is an short post I wrote in April last year on Open Source Community and since the site has been down for a couple of months now, I've managed to get it through Waybackmachine:
After much time and effort spent on battling with viruses on windows XP, I finally made a switch to linux, Ubuntu linux. I got to know Ubuntu about 2 years ago when comparing different kinds of linux distros. I've tried and done the installation of Mandrake 10, Suse 9.3, Fedora Core 3 & 4 and some other less known distros.
Of all the distro I've tried, it's undeniable that Ubuntu has the easiest interface to interact with, live cd running straight through cd-rom, easy installation and common softwares were included by default, such as open office, firefox, gaim and etc. Adding and removing program were as easy as a click and go, putting away all the bias that once said linux is only for geek. I am not a geek and I can do that, simply because Ubuntu linux got the power for me to do so.
Another sweet thing to mention is that we are allowed to request Ubuntu CDs for free with active community support.
A few stuff running on my ubuntu are open-office, evolution, gaim, skype and xchat, nothing else in particular. But the whole experence does amazed me and I am aware that this was a great move.
That's all for now, thanks Amy for encouraging me to write here, you should give your old pc a damn try on ubuntu, hehe.
The original article on opensourcecommunity.org
Tuesday, 11 November 2008 12:15
Eddy
I wrote a little script a couple months back, it was used to grab my friendster's friend listings, sort them by those who logged in within last 24 hours and had them bubbled up. It was working fine until lately, as some of the usernames were shown garbled. So I checked against their profile and it showed that a few of them are using chinese and korean characters (unicode).
The content of the script is shown below, it starts by grabbing the first page of my friendster and performs a regular expression match against the returned content based on the defined pattern, which is set to match those paging links ranging from 1 to 999 pages. It's purpose is to get the total number of pages and proceeds to loop through the total numbers, grabs the returned content, removes unused html objects and store them to $content variable. So far $content variable contains intermigled ascii and unicode characters, but they are displayed correctly when outputted.
..
$pattern = '<a href="/friends/'.$friendsterID.'/[0-9]{1,3}" />';
$null = preg_match_all($pattern, $content, $pages);
..
$getUrl = "friends/$friendsterID/$i";
..
//start looping
$fp = fsockopen ("www.friendster.com", 80, $errno, $errstr, 30);
fputs ($fp, "GET /$getUrl HTTP/1.0\r\nHost: www.friendster.com\r\nUser-Agent: MS Internet Explorer\r\n\r\n");
while (!feof($fp)) {
$content .= fgets($fp,1024);
}
..
$null = eregi("$fsStart(.*)$fsEnd", $content, $fsArray);
$content = $fsArray[1];
..
$fullContent .= $content;
//end looping
..
$dom = new DOMDocument();
@$dom->loadHTML($fullContent );
$xpath = new DOMXPath($dom);
$xpath_query = '//html/body/div/div';
$entries = $xpath->query($xpath_query);
..
$user = $entry->nodeValue;
..
Wednesday, 05 November 2008 12:06
Eddy
Google added a couple of new features to their free analytical tool late last month, a few of which are available by now : Advanced Segmentation, Custom Reporting and Motion Chart.
Advanced Segmentation
Advanced Segmentation is a tool you can use to slice and dice your Analytics data with great precision. Advanced segments allow you to choose what types of visits you want to be considered when generating the data for a report. Source : Google
One of the most important report we expect from an analytical software is traffic sources, it gives us visualization of where our web traffic are coming from. In Google Analytics, there are 3 primary sources of traffic: organic (traffic generated from search engine), referal and direct traffic. And with Advanced Segmentation, extra infomation would be displayed with each subsequent metric and dimension filter. Here are a few screenshots from our analytical report:
 4 segments of traffic sources
Wednesday, 22 October 2008 12:06
Eddy
There are times when we want part of our website to be excluded from Google Search result with reasons, such as when we are setting up a publicly accessible development site or demo site with lots of dummy contents. One way of doing that is to set up a disallow rule in robots.txt to the respective site or add a meta noindex tag to prevent googlebot or any searchbot from crawling those dummy contents.
However, as forgetful as some people are, just like me, when we haven't already put the disallow rule or noindex meta tag onto our sites, those diligent searchbots had already started crawling our sites at full speed. Here is the crawl stat of googlebot on this site over the past few weeks:

I have had 2 subdirectories of this site removed from Google Search listing recently, one of the sub-site was used to showcase my Joomla Jobboard Component which contains Joomla default sample contents and Jobboard Component dummy contents and another one was used to test Sweetcron Lifestream software, because many of its links are unnecessarily cluttering the Google Search result with not-so-worthy contents.
I used Google Webmaster to remove those 2 sub-sites, if you haven't got started using Google Webmaster yet, go do that, it's free and effective!
Once logged in, there are a few sections within the dashboard and since we're dealing with content removal, let's head to Tools ยป Remove URLs and the rest are self-explanatory.
Tuesday, 14 October 2008 12:10
Eddy
So you've learnt how to create and customize Magento Theme or even have your custom-made theme ready to be shared with Magento Community? Before we go into details of packaging a theme, we should know a few basic terms and principles of Magento Extensions. Extensions could be of usage type of modules, language packs, design interfaces and themes and they are of 3 types of contributions:
- Magento Core Extensions, these are extensions created by Magento Core Team and released under OSL 3.0 license.
- Magento Community Extensions, these are extensions created by Magento Community Members and released under any open-source licenses.
- Magento Commercial Extensions, these are extensions created by Commercial Third Party and released under their own licensing scheme and hosted under their own server.
Since we'll be sharing the theme with Magento Community, our extension is categorised into Community Extension. Every submitted and approved community extension will have an extension key which is used when users are installing it through "Magento Connect Manager". Let's take a popular blogging extension: Lazzymonks Blog as example, it has a key of "magento-community/Monk_Blog".
|