Monday, June 1, 2009

Colnect's Alexa Ratings goes up up up...


A previous post about Colnect's ratings on Alexa had been posted about 4 months ago. Colnect's Alexa ratings had kept climbing through the time and
now standing at ~103,000, whereas ~4 months ago it was ~184,000, ~7 months ago it was at ~360,000 and ~9 months ago ~500,000. Climbing up from now on will probably be slower on the absolute numbers but not on the actual traffic which keeps growing and growing as Colnect is offering its services to new crowds of banknotes collectors and bottle caps collectors.

Saturday, May 30, 2009

Banknotes and Bottle Caps Google Gadgets

Do you see the random collectibles on the side of this blog? These are Colnect's iGoogle gadgets.

Following the recent addition of banknotes and bottle caps to Colnect, the matching Google Gadgets, showing a random collectible, are now available.




They can easily be added to your iGoogle page, blog or website using following URIs.

Banknotes:
http://colnect.com/integrations/google_gadget/collectibles/banknotes

Bottle Caps:
http://colnect.com/integrations/google_gadget/collectibles/bottlecaps

The previous gadgets are also available:

Coins:
http://colnect.com/integrations/google_gadget/collectibles/coins

Stamps:
http://colnect.com/integrations/google_gadget/collectibles/stamps

Phone Cards:
http://colnect.com/integrations/google_gadget/collectibles/phonecards

Friday, May 29, 2009

Banknotes for Collectors on Colnect


Banknotes are now available on Colnect and collectors from around the world can manage their personal collection using the catalog offered on Colnect, already with over 15,000 banknotes.

New categories can be added to Colnect and if you're a collector of any mass-produced collectible you are most welcomed to help and add your favorite collectibles.

Over a hundred collectors have helped out to create Colnect's catalogs.

Colnect's phonecards catalog is the world's most extensive, currently with ~157,000 phone cards listed. Colnect's coins catalog is the world's biggest free coins catalog, currently with ~15,000 coins. Colnect's stamps catalog is growing quickly and already has over 68,000 stamps listed. Colnect's new bottle caps catalog already has ~5,400 bottle caps listed.

Sunday, May 24, 2009

Collectible Bottle Caps for Collectors on Colnect


Bottle caps are now available on Colnect and collectors from around the world can manage their personal collection using the catalog offered on Colnect.

Colnect's catalogs are created by volunteering collectors and updated constantly. The initial catalog of bottle caps, already with over 5,000 bottle caps, has been contributed by one member of Colnect, Paul Giba.

More categories will soon be added to Colnect and if you're a collector of any mass-produced collectible you are most welcomed to help and add your favorite collectibles.

Over a hundred collectors have helped out to create Colnect's catalogs.

Colnect's phonecards catalog is the world's most extensive, currently with over 155,000 phone cards listed. Colnect's coins catalog is the world's biggest free coins catalog, currently with over 14,000 coins. Colnect's stamps catalog is growing quickly and already has over 68,000 stamps listed.

Friday, May 8, 2009

How Colnect's Winning Pitch Was Made

Colnect had surprisingly won the Startup2.0 competition in Bilbao, Spain. Out of ~160 companies, 11 made it to the finals where each company had 3 minutes to pitch and 4 more minutes for Q&A. This post will describe what I consider the key points that have made Colnect's pitch stand out and perhaps one of the reasons for Colnect winning the competition.

Planning


Perhaps 3 minutes don't seem like a lot of time but consider that some "elevator pitches" last only 40 seconds, so 3 minutes is a lot. In my opinion, a major mistake is to try and showcase all you have in a short amount of time. When time is of the essence the aim is to impress. So the initial plan was to use the 3 minutes to give a basic introduction and impress the audience without getting into any details. Considering the fact that 11 companies were going to display, Colnect would have to stand out.

Promotional Video


If you haven't watched it yet, you should now:



The idea to use puppets for the video came from my brother Ofer and help in creating the video came from my friend Matan and his friend Eric.

Impressive key points were emphasized in the video:
* Colnect's availability in 35 languages.
* Colnect having a great community with over a hundred volunteers.
* Colnect answering a real need for collectors - its target market.

Q&A



Intentionally, I have not answered the most common questions (business model, current status, competition, etc.) in my 3 minutes part. I guessed that it would mean I'd get to be asked these questions rather than (potentially hazardous) unexpected questions or (much worse) no questions. Detailed answers to the common questions were prepared and I could use my "cheat sheet" in answering the jury's questions.

As a minor gimmick, I put on the frog puppet (Frognector) from the video on my hand while the video was being watched and as the video finished showing, I opened with: "Frognector is now available to answer your questions". I actually expected a bit more laughs but I'm sure it attracted attention to myself. Some of the jury members were using their laptops paying half (or less) attention on other presentations. My "bending the rules" a bit ensured more attention. Though I risked being seen as a joker, I believed that the ready made answers would make up for any such impression.

Aftermath



Not that a good presentation would necessarily take you where you want to go but a bad presentation will most likely NEVER take you where you want. Try to think who your target crowd is and how they would look at it. For example: when doing a 1on1 meeting the gimmicks may be completely stupid but when you need to stand out from the rest, they're probably essential.

Monday, April 27, 2009

Colnect wins Startup2.0 competition!!! nonick 2009, Bilbao, Spain

An astounding surprise, Colnect has won Statrup2.0 competition held as a part of the nonick conference in Bilbao, Spain.

Startup2.0 featured ~160 companies from all over Europe, of which 11 companies made it to the finals. All members of the jury unanimously voted for Colnect! The greatness of the achievement is even more vivid in the light of the grave difference between Colnect and most other contenders. Colnect has never received any funding and has been run solely by its single founder, Amir Wald, also writing this post.

Second place went to Genoom from Spain, a social networking platform designed to build private family networks. Third place went to Twidox from Germany, a free, user generated library of ‘quality’ documents that allows individuals and organizations to easily publish, distribute, share, and discover them.

Official announcements are found here and here.

Colnect's new promotional video, created for the competition, was met with spontaneous ovation from the crowd. Here it is:


Colnect's founder, Amir Wald, receiving the award:


More personal notes about the event will soon be published. Thanks to everyone organizing, participating and supporting Colnect.

Friday, April 17, 2009

Colnect got the the finals on Startup 2.0 2009

Colnect was chosen as one of the finalists to compete on Startup 2.0 competition to be held 24-25/April in Bilbao, Spain.

This year, 157 start ups participated, of which 11 were chosen to present in Bilbao. Three of those will win by a jury's decision. Though I believe Colnect is an extremely unique, interesting and useful project, its lack of any external funding may make it a little rough of the edges and so I'm lowering my expectations (though not my enthusiasm) in advance. Not many stay awestruck and drooling when seeing the intelligent special girl walking on the beach, most reserve their saliva for the fit hottie in bikini ;)

From their site: "
Startup2.0 is a competition of European web 2.0 sites whose objectives are to promote and reward the European startups (either created or willing to do so in the future) that work in the field of 2.0 technologies."

UPDATE: The finalists announced here

Wednesday, April 15, 2009

Paypal + Unicode - part 2

A previous post here was showing problems occurring by PayPal's inability to receive UTF-8 encoding. Although I still consider it a major PayPal fault, it may be possible to override this bug by setting your site's encoding on your PayPal account. When you find the 'Edit Profile' link under 'Account' tab when logged in, there should be a link to change your language encoding. It's not very noticeable but it's there. I haven't tested it and prefer not to use non-English alphabet in the value part of the input.



Good luck :)

Invalid URL Requests From Legitimate Bots

In a former post I've mentioned that I have no idea how come invalid URLs for which no link on the site (nor sitemap) exists are being tried by legitimate bots such as GoogleBot.

Now I have a partial answer for the non existing URLs presented in the post. Some time ago, a twitter account for Colnect editors has been opened @ColnectEdits. It automatically twits about edits done on Colnect's catalogs so that other collectors may track it.



An interesting thing that you can see in the attached picture is the the links generated by the tweets are shown as http://colnect.com/en/phone... but actually do link to the correct full URLs, such as http://colnect.com/en/phonecards/item/id/9212. So it seems that the web crawlers read both as legitimate URLs and try to fetch them. Since it seems GoogleBot does not want to learn that /en/phone returns 404 from Colnect, I am now forced to add these as legitimate URLs to my site to avoid seeing more 404s in my logs. Oh well...

Phone cards catalog: biggest, most extensive, free

Happy to announce that Colnect's phone cards catalog, the world's most-extensive phone cards catalogs, has now over 150,000 phone cards listed in it.

Colnect's catalog is an endeavor of many collectors from around the world who constantly improve it.

Using Colnect's catalog, collectors from around the world can easily manage their personal collection on Colnect and find swap buddies from around the world.

Special thanks goes to all the contributors, editors and translators of Colnect.

Happy collecting :)

Monday, April 13, 2009

PayPal + Unicode ==> No Payment

So you got your PayPal merchant account for your awesome website and have created a nice button to allow members to receive the amazing premium paid services you've made for them. You create the button code using the wizard supplied on PayPal's site to ensure nothing goes wrong. Oh, your site is multilingual? Yes, so please create another button for every language. No, we cover only some of those on your site. PayPal hasn't enough resources to translate itself to all popular languages. It's probably not making as much money as Colnect that can afford to be translated to 35 languages.

So the button is on the site and you test it. It works. Hurray! That wasn't too hard. But hey, are you going to test each option on the button in each language? Yes, you should but it seems fine and PayPal is a serious website. Right? WRONG!

A member who tries to pay money is faced with this beautiful message: "PayPal cannot process this transaction because of a problem with the seller's website. Please contact the seller directly to resolve this problem."



Though you might expect PayPal to alert you when such an event happens that is obviously your fault, it never happens. You may keep wondering how much business you've lost due to this fuck up. Well, you made the mistake so you suffer the consequences. Right? WRONG!

The problem is that PayPal's server has some problem with unicode encoding. You have used the Euro sign and dared send it to their server. Your site has a problem. You have a problem. Don't you know that Euro signs are bad? The wizard that generated your code thought of letting you know it but than decided you should learn it the hard way. The hard way would be to go through technical support with a person who obviously doesn't know very much about all the relevant Internet technologies and tells you it's your fault again. It's your page header, it's your CSS (WTF?!?!), it's your bad browser cookies.

You finally create another button without the Euro sign and find out that it wasn't you after all. It was them. It is them. PayPal screwed it up. But it's your fault, you chose to use their services...



The author of this post is not affiliated with PayPal or any other similar service. The story is true. I keep being amazed at how unprofessional PayPal is. Your comments welcomed.

PayPal Opinion

The reason I'm not going to write "PayPal sucks" is probably because they seem to be somewhat better than the competition when it comes to receiving payments from around the world in a secure way. I do plan on trying MoneyBookers as well and it seems that other competitors either take hefty fees (WorldPay want 200GBP set-up fee...) and/or are limited in currencies and countries of availability.

So here's are some of the problems of PayPal for my website for collectors:

* Fees. Though almost anywhere on their site they publish the fees to be up to 3.4%, a closer examination reveals 3.9% for "cross-border" transactions (I'm sure the guy who made that bs up got a great bonus afterwards) plus a good 2.5% spread on currency conversion. So we're getting to 6.3% WITHOUT mentioning the fee per transaction and withdrawl fee.

* Support. My worst support experiences ever. Customer support first reply was always automated and faintly related to the question. Subsequent replies were never helpful. Technical support was lacking technical knowledge and misdirected me more than helping.

* Site Usability. They could have done a much better job at that. Navigation is horrible and sessions often expire. Many times I got sporadic server errors.

For the finishing paragraph I'll write the good things: setup was relatively painless and PayPal is popular and thus consumers feel secure using it.

Sunday, April 12, 2009

When Web Crawlers Attack

Web crawlers, or search bots, are very popular beasts of the Internet. They allow your site to be automatically scanned and indexed. The main advantage is that people may find your site through these indexes and visit your site. The main disadvantages is that your content is copied somewhere else (where you have no control over it) and that the bots take your server resources and bandwidth.

On my site for collectors, I have created a pretty extensive robots.txt file to prevent some nicer bots from scanning parts of the site they shouldn't and blocking semi-nice bots. In addition, server rules to block some less than nice bots out there were added.

The biggest problem left unanswered is what to do when the supposedly nice bots attack your site. The web's most-popular bots is probably GoogleBot, create and operated by Google. Obviously, it brings traffic and is a good bot that should be allowed to scan the site. However, more and more frequently I see that the bot is looking for more and more URLs that NEVER existed on the site. Atop of that, since the site supports 35 languages, the bot even made up language-specific URLs. For some reason, it decided I should have a /en/phone page and so it also tries to fetch /es/phone, de/phone and so on.

So why is that so annoying? Two main reasons:

1/ It appears in my logs. I check these for errors and end up spending time on it.
2/ The bot is not giving up on these URLs although a proper 404 code is returned. It tries them over and over and over and over again.

Any suggestions? Seems to me that modifying robots.txt with 35 new URLs each time GoogleBot makes up a URL isn't the easiest solution.

The problem is not unique to GoogleBot. I have completely blocked Alexa's ia_archiver which is making up URLs like crazy.

Are there any reasons for inventing NEVER-existing URLs? Probably broken HTML files or invalid links from somewhere. Sometimes, wrong interpretation of JavaScript code (do they really HAVE TO follow every nofollow link as well???) seems to be the reason.

2009/04/15 - Read the update

Tuesday, April 7, 2009

Colnect Rising on Compete


Though I update about trends in site metrics for Colnect, I'm not really sure what they mean as they don't always coincide with my Analytics results. You're welcomed to check Colnect's rankings on Compete. It has risen 34% in the last month. Pretty nice :)

Sunday, April 5, 2009

GMail turn 5 - still BETA??? Colnect will not follow.

Gmail's official blog announced that Gmail celebrates it's 5th birthday. 5 years is not a short amount of time. However, GMail is still in BETA. It seems that Google has changed the common meaning of "BETA" from "publicly available product about to go fully public when final fixes and additions are made" into "fully fledged public product that is expected to sometimes fail and we won't take responsibility for it when it does".
Google even created the 'beta' mark trend in logos of companies and services.

I personally find it rediculous and unfair to the customers. Of course products sometimes fail but we cannot abuse the term "BETA" for 5 (FIVE!!!) years.

Colnect has been marked as beta for less than 6 months since it went public before all key features were ready and prior to proper testing. Raising a site from grass-roots up is not a simple task. However, as of today, since Colnect is relatively stable and many of its key features (a lot more is to come but I'll elaborate on that another time) are ready and publicly available, the BETA mark will be removed.
Yes, my system may sometimes fail. Yes, it's not as perfect as I'd like it to be. However, it's public, it's working, it makes many people using it happy so it's not a beta anymore.

Thursday, April 2, 2009

Buying and selling collectibles

A recent addition to premium members of Colnect are the buy and sell lists. You can read all about them here.

Buy List / Sell List

These lists are available with Premium Membership. Unlike Custom Personal Lists, collectibles added to these lists appear on the Collectors inventory information section of each single collectible item page.

When adding collectibles to these lists it is best to put the relevant price in the public note box. We suggest using world-popular currencies and use their 3 letter code rather than symbol. Example: USD is always US dollar, but the $ sign has different meaning in different countries.

NOTE! Prices you quote must be valid. You may add details regarding trades on your personal page under My Account. Complaints received regarding invalid prices (for example: you offered to sell an item for a certain price but later asked for a higher price) will be investigated. If you are found dishonest, your Colnect account may be deactivated without any refunds.

Japanese and Lithuanian languages added

Colnect is now available in 35 languages. The latest two additions are Japanese and Lithuanian.

Translations on Colnect are performed manually by volunteering translators who are members of the site. Whenever a phrase is not properly translated they can translate it easily. It's all explained here.

A recent addition is the use of automated suggestions. When a phrase has not yet been translated, it'll first be translated with an automated suggestion. An icon telling the translator he should translate (or confirm) that phrase still exists. The use of suggestions is intended for the period of time after a new content is published on Colnect (which is quite often) until a translator actually gets to translate it.

Yes, automated translations sometimes suck really bad. For example "FREE trial - 1 month" had a Hebrew suggestion that can be translated back to English as "Free trial - 1 year". What?!?! How did a month become a year? That is quite dangerous and I hope these mistakes are not too frequent. I hope that the automated suggestions many times "get over the net", meaning they are understood by the reader although acknowledged as improper language use.

Japanese is currently the only language for which Colnect yet has no translator and so we rely on the automatic suggestions. It's a sort of pilot to see if it can attract Japanese collectors and hopefully one of them will agree to become a translator. If this experiment succeeds, other languages may be added this way. A warning message will be displayed with languages that are not completely manually translated.

You're welcomed to check Transposh for translation solutions.

Tuesday, March 31, 2009

Twitter fails as a promotional tool?

Colnect has joined Twitter less than a week ago using a few Twitter profiles:
* Colnect news Twitter @colnect
* A personal Twitter for Colnect's manager @AmirWald
* Automated feed reporting new collectibles in Colnect's catalogs @ColnectCatalogs
* Automated feed on Colnect's catalog edits @ColnectEdits

During these days 28 visits came to Colnect from Twitter, a meager amount in comparison to the number of "followers" and energy invested. The bounce rate (visitors seeing a single page and leaving the site) was incredibly high as well. In comparison, a few posts on a relevant forum resulted in hundreds of relevant visits (with much lesser bounce rate).

It seems a lot of people use Twitter to self promote and so it's more of a bubble where "followers" is a rough indication of the number of people who will actually read anything of what you write. My guess is that for most people, a small percent of their "followers" actually read more than 5% of their tweets. Though some people think of it as a useful personal tool, it doesn't seem like they dominate Twitter.

Though less than a week may be a too short amount of time for a verdict, results so far are very unsatisfying. In the future, the automated feeds may be of use to some of the addict collectors on Colnect. Let's see what the future brings.

Wednesday, March 25, 2009

Colnect on Twitter

Giving up to the fad? Possibly...
Easier than blog posts? Obviously...
Useful? hmmm.....

Anyway, you're welcomed to follow the official Colnect on Twitter
All public updates regarding Colnect may be there before anywhere else.

Tuesday, March 24, 2009

Custom Personal Lists on Colnect

A new much-needed premium service had just been added to Colnect.

Custom Personal Lists

In addition to the common inventory lists on Colnect (Collection / Swap / Wish), premium members can create more lists. When custom lists are added, you can add and remove item to and from them in the same way you do for the common lists.

Common Uses

  • Reserving items for a specific swap
  • Offering many item for a single sale
  • Marking items you wish to attend to later
  • Creating a list to be shown to collectors on other sites

Monday, March 23, 2009

Gmail: back to the future

The following post has nothing to do with this blog but it's just something amusing I've recently seen while using my GMail. After sending a message, it tells me my message has been sent -1 minutes ago. Are they trying to say it will be sent in 1 minute? Is it yet another bug in Gmail?


Here's the attached picture. My interface is in Spanish so "minutos antes" means "minutes ago".

Friday, March 20, 2009

Biggest phone cards catalog for collectors - 142,000+ phone cards listed

For a long time, Colnect provides the world's most extensive collectible phone cards catalog. However, the phone card collectors on Colnect keep adding information to the catalog. It has just passed over 142,000 listed phonecards. The catalog is very organic and changes as the editors on Colnect receive feedbacks from collectors. It's freely available for browsing even without the need to register. Free registration to Colnect allows collectors to also manage their personal collection.

Coins catalog: over 14,000 coins

Quietly but surely, Colnect's coins catalog, being built by coin collectors for coin collectors, has surpassed 14,000 listed coins. It's freely available for browsing even without the need to register. Free registration to Colnect allows collectors to manage their personal collection.

Colnect's coins catalog is currently the world's biggest freely available resource for coin pictures and information.

Wednesday, March 18, 2009

Colnect rises on Compete / Quantcast / Alexa



I've been updating about Colnect's rank rising on Alexa and have now decided to include links to other rankings. So you can check out Colnect's rankings on Compete and Quantcast and start wondering what all these ratings are actually worth. So although it's nice to see Colnect gains momentum on all non-related meters, it's interesting to note the difference between what they report and between the reality. By "reality" I usually mean my reports from Google Analytics and, when really bored, the server's logs can be inspected. There's little connection between the real graphs and the estimated ones by these services. Colnect has been growing and growing throughout. Sometimes slower, lately faster. The graphs by Compete and Quantcast actually show a very inaccurate picture. Oh well...

Monday, March 16, 2009

Collectors premium services on Colnect

A few days ago, Colnect's premium services for collectors have finally opened up. Colnect has already been offering a respectable set of free services to collectors from around the world. These free services will continue to be offered for the benefit of the entire collectors community.

The announcement has been made:
"Premium membership gives you access to several features that will enhance your Colnect experience. If you regularly use Colnect, please consider supporting us by becoming a premium member."

Currently, not many premium services are offered but these will be added with time according to collector demands.

Happy collecting :)

Sunday, March 8, 2009

Colnect's Alexa Rating Keeps Climbing

Since the last post about Colnect's ranking on Alexa, it has risen again, now standing at 144,039 whereas a month ago it was 184,627, ~4 months ago it was at ~360,000 and ~6 months ago ~500,000. More information on my previous post about the subject.
The ranking is coherent with Colnect's internal report, showing a significant increase in traffic during the last months.

Wednesday, March 4, 2009

Email Anti-Spam Tip

This tip will not completely prevent spam but will enable you to quickly deduce if you've got spam, how you the spam and help you decide what to do with it. It's quite simple, have your own email domain and give different email addresses at different places.

An Example


Today I've received this unsolicited (SPAM) email trying to frighten me into buying colnect.tw, colnect.cn and so on. Here it is:

From: kevin.wu

(If you are NOT CEO,please forward this to your CEO, because this is urgent.Thanks.)

Dear CEO,

We are the department of registration service in China. we have something need to confirm with you. We formally received an application on March 3, 2009, One Japan company called "Path soft investment Corp" are applying to register (colnect) as internet brand name and domain names as below (colnect.net.cn colnect.org.cn colnect.mobi colnect.asia colnect.hk colnect.cc colnect.tw etc.).

After our initial checking, we found the internet brand name and these domain names being applied are as same as your company’s, so we need to get the confirmation from your company. If the aforesaid company is your business partner or your subsidiary company, please DO NOT reply us, we will approve the application automatically. If you have no any relationship with this company, please contact us within 15 workdays. If out of the deadline, we will approve the application submitted by "Path soft Corp" unconditionally.

We would like to get the affirmation of your company,please contact us by telephone or email as soon as possible.

Best Regards,

Kevin Wu
Senior Director
TEL: +86 21 69929440
Fax: +86 21 69929447
Website:www.qpnic.org.cn
Shanghai QPNIC Web Property Solutions Limited


Now, this email was sent to management@ and webmaster@ (both of them at my domain colnect.com). However, since I never give these email addresses to anyone, it means that every email I get there is SPAM. Other common names such as info@ and contact@ and others are frequently used.
A short search on the Internet affirmed my suspicion of a scam, when I found this blog post and that one.

What About My Private Email?


Well, you can easily get yourself a free domain on any service that would freely forward your email (such as cjb.net). Then, whenever you register a website, make up an email site_x@mydomain.cjb.net and use it to register the site. You would always be able to receive such emails but when this address becomes 'dirty' (starts receiving much spam), you can filter out all emails coming to it. It's a better solution than one-time emails since sometimes you do actually want to allow the site to later contact you. It is also a completely legitimate email address.

Symfony: Error Logging Hack

Symfony is an excellent PHP framework used on Colnect. As any piece of software, however, it has its shortcomings. The good thing is that I can hack it to fit my needs when some things are not to my likings. A recent hack I've done (and should have done a long time ago) is about the error logs. Though the guidebook to Symfony describes logging at length I couldn't figure out how to easily add some useful information to any Exception thrown on my production machine.

The following hack can be has been customized for my needs but you can change it to your preferences. It'll change the output Symfony places in the PHP error log file.

What the Hack Does?


A boring Exception such as:
[04-Mar-2009 17:20:25] Action "coins/collect" does not exist.


Will become:
[04-Mar-2009 17:20:25] CODE[0] MESSAGE[Action "coins/collect" does not exist.]
FILE[.\config_core_compile.yml.php] Line[715]
REQUEST[/it/coins/sdlk] REFERER[]
AGENT[Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.6) Gecko/2009011913 Firefox/3.0.6] ADDR[127.0.0.1]


How To?


Find sfException class (should be /symfony/lib/exception/sfException.class.php) and add the following method:



public function getMessageFull() {
$exception = is_null($this->wrappedException) ? $this : $this->wrappedException;

try {
$sReq = isset($_SERVER['REQUEST_URI']) ? $_SERVER['REQUEST_URI'] : '';
$sRef = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '';
$sUserAgent = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : '';
$sRemoteAddr = isset($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : '';

$sErrMessage = "CODE[".$exception->getCode().'] MESSAGE['.$exception->getMessage()."]"
."\n\tFILE[".$exception->getFile()."] Line[".$exception->getLine()."]"
."\n\tREQUEST[$sReq] REFERER[$sRef]"
."\n\tAGENT[$sUserAgent] ADDR[$sRemoteAddr]\n"
;
}
catch (Exception $e)
{
$sErrMessage = $exception->getMessage();
}

return $sErrMessage;
}


Customize this method to your needs. Make sure it doesn't raise any exceptions itself.
Now you need 2 more small changes in both sfException.php and sfError404Exception. Change the line:
error_log($this->getMessage());

to:
error_log($this->getMessageFull());


More Enhancements?


It's your call. You can email yourself an alert, include more system-specific pieces of information or use the code as is. It's obviously not the cleanest solution possible but it works for me and hope it helps you.

Wednesday, February 25, 2009

3,500 collectors on Colnect

Yesterday Colnect has passed the mark of 3,500 registered collectors. This is an increase of over 17% during the last 2 months. Just before starting this year, Colnect had passed the 3,000 collectors mark. Considering the fact that ridiculously little marketing work has been done (~$50 spent on ads...), I see this as a very respectable achievement that continues the growth that started when Colnect V2 was released.

How do collectors learn about Colnect?


As Colnect allows collectors to manage their personal collection and semi-automatically manage swaps with other collectors from around the world, it's the collectors' own interest to have their collector friends join the site. Why would a collector go through the swap and wish lists of another collector manually when a match to his own lists can be done using a single click?

So what's next?


Colnect will expand to more collectible fields as requests come from existing members of the community. Some requested premium services are also planned.

Thursday, February 19, 2009

BE CAREFUL when using both AdSense + AdWords by Google


Do you have a website and using both AdSense and AdWords? If so, this post will interest you. You may start by looking at the attached picture.

AdWords and AdSense are the different sides of the same coin and Google is in the middle, biting on the metal. AdSense allows website owners to show different ads from different advertisers on their website and receive revenues for it. AdWords allow you to advertise your website on many other websites running AdSense. Google takes its commission for providing both these services. Though many other competing programs exist on the web, Google's generally have good reputation.

Advertising my site on my site?!?!?!


This morning, I was amazed to see an ad to my website for collectors on the same site! Had I clicked this ad, my AdWords account would have been billed for the click while my AdSense account would have received some revenue. Obviously the latter would be lesser since Google get their cut. This is, of course, ridiculous and should be automatically prevented by Google. Apparently, it isn't. Just to ensure you that I'm not an idiot, the ad is for colnect.com and the website is on the same domain - colnect.com

I usually view my own site with ads disabled so I don't accidentally click an ad and violate the terms of service. This time I was at a friend's house and am quite happy to have stumbled upon the aforementioned bug/feature.

Quick Remedy




Both accounts allow you to use filters and I've now added "competition filters" for my AdSense account that will prevent showing ads for any of my domain. It's also possible to filter out sites on AdWords but this can seemingly be done only on the campaign level so if you're running many different campaigns, it'll become tedious. See the attached pictures.

Saturday, February 14, 2009

Upto 80% Speed Increase on Colnect with Symfony

I have managed to cut up to 80% in loading times for Colnect's pages. This is going to be a technical post that would hopefully help others using Symfony framework on their websites. Please mind that for many sites, caching can and should be enabled. On Colnect, however, a lot of pages (especially the heavy ones) cannot be cached since they need be calculated on every request from the same user. If your site is not very dynamic, using APC (if you have a single server) or memcached (when you have many) is the best thing you can do for performance.

Partials are evil


Maybe not that evil but they take their toll on your loading time. The worst is when using them inside a loop as the price increases linearly. Use helpers whenever possible but make sure you load only the necessary helpers on each call and don't try to re-load helpers when inside a loop.

Re-use function results


Symfony encourages you to use methods and functions repeatedly, for example sfContext::getInstance()->getModuleName();. Obviously, the more calculations, the longer things take so whenever you need to re-use results, save the variable content.

A good PHP structure for re-using results is:

function foo_calculate() {
static $result = null;
if (is_null($result)) {
# perform calculations
$result = calculation results...
}
return $result;
}


Escaping PHP and going back to PHP takes its toll


Using
?>xxx
is more costly than
echo 'xxx';
See code on the next paragraph.

Using many echo calls slows things down



It's better to accumulate output in a variable and call a single echo.
The following code performs simple tests so you can get a feeling of the differences in execution times. Run it a few times (when all other applications are closed) since results alter a bit every time.


public function executeCompareOutput(sfWebRequest $request) {
$times = 100000;
echo 'Looping for '.$times.' times - results in msec';
echo '<-div style="display:none">';
$start = microtime(true);
for ($x = 0; $x++ < $times;) {
echo ' '.$x;
}
echo '<-/div><-br/>'.round(1000 * (microtime(true) - $start));

$start = microtime(true);
echo '<-div style="display:none">';
for ($x = 0; $x++ < $times;) {
?> echo $x;
}
echo '<-br/>'.round(1000 * (microtime(true) - $start));

$start = microtime(true);
echo '<-div style="display:none">';
$sBuf = '';
for ($x = 0; $x++ < $times;) {
$sBuf .= ' '.$x;
}
echo $sBuf;
echo '<-br/>'.round(1000 * (microtime(true) - $start));

$start = microtime(true);
echo '<-div style="display:none">';
$sBuf = '';
for ($x = 0; $x++ < $times;) {
$sBuf .= ' ';
$sBuf .= $x;
}
echo $sBuf;
echo '<-br/>'.round(1000 * (microtime(true) - $start));

$start = microtime(true);
echo '<-div style="display:none">';
$GLOBALS['bufbuf'] = '';
for ($x = 0; $x++ < $times;) {
$GLOBALS['bufbuf'] .= ' '.$x;
}
echo $sBuf;
echo '<-br/>'.round(1000 * (microtime(true) - $start));

die('<-br/>bye');
}


Here is a sample output:

Looping for 10000 times - results in msec
3044
5503
10
15
16
bye


On this run using multiple echo calls + PHP escaping took 55 TIMES MORE than buffering the output in a variable. This clearly proves that the style suggested by Symfony templates, using many PHP echo blocks, is HIGHLY inefficient. If you have a few dozens of it in your templates and your content is cached, this is negligible. If your content is very dynamic, as is the case with Colnect, we're talking about something very worth noting.

Wednesday, February 11, 2009

Colnect's Alexa Ranking Keeps Going Up

Colnect's ranking on Alexa has risen again, now standing at 184,627 whereas ~3 months ago it was at ~360,000 and ~5 months ago ~500,000. I don't even know if it's linear or logarithmic although I guess the latter.

To those who may not know, Alexa ranks many (most?) websites out there of the big WWW. It does that by analyzing the traffic of (mostly unsuspecting?) users who install the Alexa toolbar on their browsers. This nice toolbar delivers the information back to their big servers, they crunch it whichever way they like and then rank the sites according to this information.

Why would anyone care about Alexa's ranking? Well, it has come to be relatively important in the WWW world. It allows you to have some (allegedly non-biased) objective information about how your website fairs on the Internet.

Are the results reliable? The short answer IMHO: no. The longer answer: perhaps, to some length. Since some website owners/operators/SEO personnel think of it as important, they are making an effort to get their ranking up. This isn't that hard, considering the fact the grand majority of users don't have the Alexa toolbar. There are many methods but they're basically about making people who use your site have the Alexa toolbar thus your site will have an improved ranking.

Another important disadvantage of Alexa is that ranking is on a per-domain basis. As such, this blog (which a few read) ranks the same as Colnect (which many frequently use). Personal websites on some free hosting all rank the same so you cannot tell them apart and so on.

Does Colnect try to improve its ranking? No. I did think about it for some time, since after all it may look better to some people, but have decided not to. The main two reasons would be not to spend my time on metrics that don't really matter and the second that since I wouldn't install it on my machine, I wouldn't ask others to do so.

Okay, let's hope this post won't cause Colnect's Alexa ranking to crash :)

Sunday, February 8, 2009

Numbers, Numbers, Numbers...

Many collectors (and non-collectors) really enjoy statistics and so finally the long awaited counters have now been added to Colnect. So when a collectors sees all coins in Colnect by country, there's now a small number indicating how many coins of that country are available on the database. The same goes for stamps and phonecards.

The big benefit becomes clearer when looking at a collector's collection, swap list or wish list. It's then very easy to know how many items the collector has of each country, company or even series.

Here's for example the information for an expert collector on Colnect, Czech RepublicDravec

Phonecards

Collection: 7,546 Phonecards
Swap list: 1,290 Phonecards (Match with my wish list)
Wish list: 6,199 Phonecards (Match with my swap list)

Stamps

Collection: 1,137 Stamps
Swap list: 3 Stamps (Match with my wish list)
Wish list: 5,678 Stamps (Match with my swap list)

Coins

Collection: 2,155 Coins
Swap list: 301 Coins (Match with my wish list)
Wish list: 10,938 Coins (Match with my swap list)



On the back end side of Colnect, the system is very flexible in supplying the given information so the real challenge was to try and create an as-intuitive-as-possible user interface. I've recently made a post about usability and the addition of counters and simplification of the user interface that followed is a big step forward.

Friday, January 30, 2009

Phonecard Puzzles

When a few items can be combined to a bigger one, it's a puzzle. A new and unique feature of Colnect shows the combined puzzle items together so that collectors may see the whole puzzle, even if they've not yet obtained the physical items. Puzzles are more common for phone cards but may sometimes be found with stamps as well.

Click here for an example Disney puzzle

or better
All phone card puzzles on Colnect

Monday, January 26, 2009

Usability

A good system doesn't only have to offer users worthwhile services but should be as easy and intuitive to use as possible. When people access so many websites, they expect everything to be natural for them. Rarely do people actually read long HELP sections. Frequently they simply play around with the application and what they can't see quickly would many times never be used.

Though these are old news, the user interface on Colnect V2 has initially not been properly designed and implemented. I admit this was a big mistake since it made the usage of existing users much more awkward and wasn't inviting enough for new users. Though Colnect did grow very nicely since V2 has been released, it's likely despite the user's interface rather than because of it.

So the good news is that in the recent days and upcoming days the user's interface will be added with many useful options to make the usage of Colnect as easy and intuitive as possible.

Here are two examples for recent additions:

CSS-only popup menus




Sorting collectors lists by clicking the column header


Friday, January 9, 2009

Colnect's Minor Contribution to World Peace

As Colnect embraces collectors from all parts of the earth and of different languages, it adds a small contribution to world peace. I strongly believe in promoting peace on the individual level. We are all people and though we may differ in our views and culture, we share so much in common. Getting closer to people of different backgrounds allows us to be more open minded and accepting of the differences. When collectors connect, they also make friends in distant places and learn about other countries and cultures.

Colnect's platform allows translation to any language so that people of different cultures can join us and enjoy sharing their hobby with others. Currently 25 languages are translated properly and 5 more are pending translation. All translations are done by volunteers and so any new language is welcomed.

Colnect does not promote political discussions since there are other, more suitable, sites for that. The lack of politics on Colnect allows all to join in and make friends without prejudices.

Though personally I come from a turbulent region, Colnect isn't and wouldn't be identified with any specific country or political stream. The English language is used as Colnect's base language only because it's the most popular language on the web world for now.

Happy collecting and peace to us all :)

Wednesday, December 24, 2008

Very happy holidays :) Over 3,000 collectors on Colnect

As 2009 is looming, Colnect has happily announced that its community now has over 3,000 members. Colnect's community growth rate has been on the increase, especially since the new Colnect V2 site has been launched during the midst of October. Since now Colnect caters to stamps and coins collectors, it has found a new crowd of people interesting in managing their personal collection easily and connect with other collectors from around the world.

Colnect's development relies on the assistance of its ~70 contributors who volunteer to translate Colnect, update its database with new collectibles and help with various tasks.

Though this blog has recently been quiet, a lot has happened on Colnect recently. The lack of a PR department in Colnect takes its toll and certainly Colnect would have bloomed much sooner with such. New features and fixes are added daily to the site and the contributors help update the catalogs on a regular basis. Colnect's collectors forums provide more detailed information about recent updates to the site.

Wednesday, November 5, 2008

iGoogle Collectibles Gadgets

Colnect has just released 3 iGoogle gadgets that you can see right here on the side of this blog. Read all about these cool collectibles gadgets.

Here's the description:
A cool gadget for collectors! See a new random collectible item. Click the picture to see complete information about the item: which memebers of Colnect Collectors Community have it on their collection, swap or wish list. You can easily manage your personal collection on Colnect and find swap buddies from all around the world. The huge catalogs on Colnect are created by collectors for collectors. Join Colnect now. It's fun, it's quick and it's free! Happy Collecting :)

Some personal thought about the current crisis

The economy fluctuates. It's actually a part of the bigger truth saying "the only constant thing is change". As with every change coming, you can either fight it or embrace it. Since fighting many times does no good, IMO one should embrace change and see how to get accustomed to new situations as they arise.

Colnect is embracing the change in the economy. So far it has maintained a positive cash flow and will continue to do so in the future. Now is probably not the time for big spendings or risk takings. Now is the time to spend less but do more with the resources available.

An interesting campaign I've came across made me even more aware of how some companies (as well as some people) do not try to prepare for a gloomier future although the writings are clearly on the wall. The campaign was for mobuzz.tv, which I haven't known before. Apparently, they're burning 50 grands a month in producing 5 daily shows a day and now they're vying for donations because they've ran out of money. They expect to raise Euro 120K in one week with donations of 5 Euro. Yes, they really expect 24,000 people to donate them 5 Euro each in a week. They just need it for 3 months and then they'll get the funding they need.

Pardon me cynicism, but I'm not even sure that FaceBook, with its huge worldwide users community, would have been able to raise 24,000 donations in a week. There are probably much sadder things happening in the world today to which one would donate. Skinning living dogs & cats is one of them.

The truth is that although I have no idea about mobuzz's business, it seems (at least on the surface of it) that someone there has not done a brilliant job planning the business side of the company. How do you get to run out of money in a week? Can't you tell when you have only 6 more months to live and then do your best to raise capital alongside with cutting expenses sharp? How can you be sure to get funding in 3 month? In a happy market you can't be sure about it, so now?

The technical side might have flows as well since there was no link to their shows to see what it is we're supposed to help with. Also, the video took very long to load.

My guess is that mobuzz isn't the only company that's about to close its doors soon due to problematic financial planning. As times get rough, survival of the fittest prevails once more. Heed the warnings out there and be ready for the future. Every storm eventually ends. Good luck to everyone.

Monday, November 3, 2008

Who hacked the network on Google Developers Day 2008 in Israel?

Though the event seemed to be organized quite well, there were network problems occurring which were the reason for me leaving the gathering earlier. At some stage I've got a warning on my browser about invalid certificates for Google.com and naturally didn't decide to accept the invalid certificates. I've told others around me that someone has probably been hacking the network but seemed most people were reluctant to believe it.

Turns out I was right, here's the email sent form "The Google Developer Day Team":


Developer Day
3 de noviembre de 2008 11:02
PLEASE READ: Unauthorized network activity at Google Developer Day

Dear attendee,

First of all thanks for attending Google Developer Day yesterday, we hope you found it useful. Unfortunately, we need to let you know about an incident which took place during the conference which you may need to take precautionary action on.

We identified unauthorised activity on the public wired Ethernet network which was provided by the convention centre for conference attendees to access the Internet. This may have affected a limited number of attendees accessing websites and online applications through the wired Ethernet connection. We have no evidence so far to suggest that the wireless network also provided at the event, and which was used by most attendees, was affected.

Due to the unauthorised activity, there is a chance that if you used the wired network, any user name and password entered to access a website may have been put at risk. When trying to access a secure website (a website using https), you may have received an alert indicating that the page had an invalid security certificate. In any case, we advise users as a precaution to change the passwords for any websites or services they accessed through the wired connection during the conference.

We're really sorry that this has happened but we believe that the vast majority of attendees won't have been affected by this incident. In the meantime, we look forward to seeing you at future events very soon.

The Google Developer Day Team

Sunday, November 2, 2008

Google Developers Day 2008 in Israel

Google's Developers Day 2008 tour has landed in Israel today. Google is looking for developer love and is doing their best to attract it. The main message coming from Google is "Let's work together to make the Internet a better place. The better it is, the better we're all off". Not forgetting that we're talking about a commercial company, not a charity foundation, their approach is, at least on the surface, quite amiable.

Perhaps the most interesting parts of the day, in regard to Colnect, were related to OpenSocial. From their website: "OpenSocial defines a common API for social applications across multiple websites. Built from standard JavaScript and HTML, developers can create apps with OpenSocial that access a social network's friends and update feeds. By using a common API, developers can extend the reach of their applications more quickly, yielding more functionality for users."

What does it really mean? As I see it, FaceBook has taken too big a share of the social networks world than Google (and others) think they deserve. One of the main reasons for the success of FaceBook is the FaceBook applications written by developers and extending FaceBook's functionality in many different directions. The problem is that developers are mostly unable to devote many efforts to writing their social applications to all social networks out there and would thus focus on the biggest ones. Orkut (Google's social network) is surely not the biggest and so the way to convince developers that they should write Orkut-complaint applications, we now have OpenSocial.

OpenSocial supports other networks as well which altogether (according to their figures) serve nearly 500 million users worldwide. Though I'm skeptical of how someone knows my Linked In and Orkut accounts are of the same person (they probably don't share email addresses around), it's still quite a big figure which should be a motivation enough for a developer to focus on it instead (or in addition to) FaceBook.

Colnect is about to release some social applications to the social networks world to assist collectors integrate their collectibles hobby with their other activities and help spread the word about Colnect to fellow collectors. OpenSearch seems an appealing choice since it involves many networks which cater to different crowds which altogether might coincide better with Colnect's target crowd than FaceBook.

Last but not least, there's the issue of Chrome, Google's new browser. While promoting it as simply a means to make your surfing better, it would still have been a bit more amiable and transparent to say "we've made our own browser so that we can make Google search the default search engine and not allow you to block AdWords ads with some addon". If Google really would have cared just for the web users community, it would have simply put more efforts into the existing open source browsers. In my experience, Chrome is still much inferior to FireFox.

Tuesday, October 28, 2008

50% increase in Colnect's growth rate - welcoming stamps and coins collectors

Less than 2 weeks following the initial release of Colnect V2 and without any commercial advertising of Colnect, there are already ~90 active coins collectors from 35 countries and ~50 active stamps collectors from 25 countries on Colnect. Active refers to a collector who has updated his/her personal collection on Colnect.

The overall amount of newly registered members during the last week shows ~50% increase over the weeks before it. This achievement, enhanced by the facts that the new site experienced some downtime and that registration now requires email address confirmation, should probably be attributed to the collectors who already know Colnect. Some collectors collect more than a single collectible and so many phonecard+coin collectors would know other coin collectors and let them know about how useful Colnect would be for them.

To help motivating collectors the following news item has recently been published on Colnect:

Help Colnect and Win Free Phonecards!

Colnect now has a huge stamps and coins catalog. However, since it's so new, many collectors of stamps and coins have not yet heard about us. Now is your chance to help Colnect and win free phonecards.
How?

Simply tell your collector friends to join Colnect. Once they join and update their collection, they should Contact Us and tell us you told them about Colnect. Every friend that joined Colnect with your help entitles you to 10 points. Each friend your friend bring, gives you 3 more points.
Who will win?

The 3 collectors who has accumulated most points until the 30th of November.
What will you win?

First place: 50 Phonecards
Second place: 40 Phonecards
Third place: 30 Phonecards
BONUS: A Colnect T-Shirt.
Questions?

Visit the forum for answers.


What about commercial advertising


Though so far Colnect did not rely on any commercial advertising but rather 'word of mouth' and friendly reviews and backlinks, it may be a good idea to advertise it some more with AdSense or a similar program. For the time being, I prefer to see a steady growth while I'm fine tuning the system and perfecting it rather than a flood which will make Colnect buzzing and later endangered.

150 OpenSearch plugins for Colnect

"OpenSearch is a collection of simple formats for the sharing of search results" the official website says. OpenSearch makes interfacing a website in which you use a lot of search much easier since you don't have to navigate through the site's pages to see the results. You skip waiting for a new page and save yourself some time.

Colnect supports OpenSearch for the benefit of the collectors on the site who often search the huge catalogs for the items they're interested in.

In Firefox:

and IE7:


Yesterday I've tried to publish the plugins on Mycroft Project so collectors could easily install from there as well. It's probably the web's most notable directory for OpenSearch plugins. The problem is that Mycroft has no auto-submission feature to be found and so I couldn't add all the plugins.

"How many plugins have you made?" you might ask and the answer is quite simple. There's one plugin to search for a collectible item by name and another to search for a collector by username. Later I may add searching by catalog code. So what's the problem submitting 2 plugins manually? Well... that 2 turned into 150 since currently there are 3 collectible types on Colnect (coins, stamps and phonecards) and the site is supported in 25 languages. 2 times 3 times 25 gets to 150 and that's not so much fun to do manually anymore... I hope they'll come up with a solution. The best would be to use simply submit the site's URLs and let MyCroft use the auto-discovery link tags like the browsers use to allow you to add the plugin.

Happy OpenSearching...

Sunday, October 19, 2008

Colnect V2 is now LIVE! :)






Following a long period of hard work, Colnect V2 is now up and running. It is a completely new version of the familiar Colnect. Its huge catalogs, from which any collector can easily manage his/her personal collection, currently include nearly 12,000 coins and over 120,000 collectible phone cards. As the catalog information is contributed by collectors, the catalog is expected to grow very quickly in the coming months.

Colnect V2 is available in 25 languages accommodating for the needs of collectors from all around the globe.

Go check out the site and register if you haven't so far. We're on the way to revolutionize the collectibles world.

Saturday, September 20, 2008

Performance: MySQL, APC, memcached.

A highly important issue of any notable website is performance. You may have created the best website in the world but if it dies under load, you're gonna lose customers. User experience is very important today and having a slow website doesn't help at all.

Optimization is, however, not a trivial issue and requires expertise in different fields. There are so many different places where you can optimize that it's not always that easy to know what to focus on. Though this post will adhere to its title I'll still list here where optimization can occur in a website.

* Correct usage of HTTP headers to make client browsers request less information.
* Smaller responses (gZIP / more CSS - less HTML / use of Ajax to return instead of reloading complete pages).
* Optimization of your server machine(s) hardware AKA "I need more CPU, I need more memory and 'how much is another 1U?".
* Server software optimizations: Webserver (such as Apache) / Scripting engine (such as PHP) / DBMS (such as MySQL) / cache engines (such as memcached, APC) could and should be tweaked heavily. Failing to define an appropriate index in your DBMS or making some wrong choices on where and when the webserver saves user sessions, for example, could carry a heavy toll.
* Network optimizations: anyone said CDNs?

The fun part is that all these parts are well entangled.

I've read an interesting post about prefering MySQL cache over the popular memcached in some situations. Though it was pretty much one-sided (ignoring the overhead of a database connection), it rose some interesting points and is well worth reading.

An advantage towards the DBMS that I consider relevant is greater flexibility. For example: you allow outdated information to persist (such as statistics). Say you want it updated about every 5 minutes. If you cache it for 5 minutes it'll expire and then you may face a situation in which a few threads query the database again to get this information. If you use a Memory table for this information you can read it and, if expired, set some writing lock that'll cause other thread to keep reading the expired information until it's well updated.

Another interesting older post about performance showed some interesting benchmarks. The biggest problem of relying on others' benchmarks is there can always be one single parameter different on your system that would mean the results for you would be totally different. For example:
* A new version of a product has just changed everything about it.
* A configuration option made a product completely flunk its benchmark tests.
* Your queries may not be similar at all to what is tested (though you may think it is).

So these were my 2c about performance for now. The bottom line is simple: there's always a part of your system that's not properly optimized. The best is to check the painful spots and remedy them while maintaining an overall look of what your system has to provide.

Friday, September 12, 2008

Colnect V2 alpha site is up for the Prague Fair

During 12-14/9/2008 a big international collectors fair is being held in Prague. To allow collectors to preview the new version of Colnect, which includes a vast database of stamps, the alpha site has been opened and is available here.

At the moment it is NOT yet considered stable and is meant only for the taste of how Colnect would be. Hopefully, it'll be ready by the end of the month and the current Colnect will be replaced by the new improved one.

There are many new things in Colnect V2 but perhaps the most important ones for current Colnect members are the addition of versatile filters to the system which allow collectors to easily find the items they're looking for and match them with collections of other collectors.

Updates to follow...

Thursday, September 11, 2008

The "Language Icon" initiative

Colnect is currently available is 25 languages and so there should be an easy way to let users choose their preferred language. To facilitate this, there's currently a big part of the welcome screen that shows the names of the different languages. The reason is that it's highly important that a user would see their language available when first visiting the site since for many people using their native tongue greatly improves usability.

Having a big box with all language names is something I can get away with on the main page but not on every page of Colnect. The problem is not when registered members (who will have their preferred language loaded as they log in) but with new visitors. For this reason there's currently a selection box on the top and side menu which allows to change a language quickly for every page.

A small issue remains: what do you write in this selection box? Currently, the English word 'Language' appears there. The word itself could have been translated to every language but seeing this word in a language you probably don't understand (if you understand it, why would you change your language?) won't be very helpful. This is not ideal but I have to assume every Internet users knows at lit a tiny bit of English (sorry all, but English is the web's most international language).

I've considered the option of using flags but have ruled it out because:
1 - Flags represent countries, not languages. Consider English which is widely spoken in the US, UK and Canada. On the other hand, consider Canada which has both English and French as official languages.
2 - Adding 25 flag icons for every page is an extra communication load with no good justification.

A solution?

An interesting project I've came across is the 'Language Icon'. They've decided to create an international icon to mean the word "language". Here it is: Classic Icon 32 x 32
It's supposed to look like a tongue though personally I don't find it resembling a tongue. If it'll catch on, however, it could be of great use to websites / application around the world. Kudos for the idea!

I've already added this icon to Colnect V2, about to be released to the public soon, where you can find it on the side menu on internal pages.

Thursday, September 4, 2008

How traffic changed from PR0 to PR4

More than a month ago, Colnect's PageRank has changed to PR4. Now's the time for some statistics taken directly from Google Analytics deployed on Colnect.

Comparing the last 2 weeks with the 2 weeks before the change show 25% more traffic from Google. But what's more interesting is that there's 68% more traffic from Live and 58% more from Yahoo. So the PageRank probably did make a difference but is Yahoo and Live taking their information from Google? Perhaps it was vice versa and I just never stumbled upon tools to test my ranking with these search engines due to the lesser amount of traffic they bring.

Doctrine v1.0 is finally out

Colnect V2 (including stamps and more collectibles) is now almost ready to be shown in alpha and that's why it's such good news that Doctrine v1.0 has been released.

Doctrine is a PHP ORM that is nicely integrated with Symfony. It allows defining your database schema easily with YAML files. The database and PHP classes can then be automatically generated to provide you will all the needed functionality of database interaction.

Although IMO some edges have not yet been met in Doctrine (most importantly the i18n support), I hope it'll be able to work properly on the new Colnect. Developing with an ORM is surely much easier to maintain than using raw SQL. I expect Doctrine to keep growing stronger and more stable in the near future as the ideas behind it are very useful and needed.

Monday, August 25, 2008

Adjusting CSS to RTL languages

Writing the new version of Colnect from scratch, I've decided to start using more CSS and less HTML table tags where possible. Truth is I'm still not sure that this decision will hold as CSS still seems immature to me. Yes, it's been around for years and it has many proponents but the truth is that sometimes you really have to work hard to do something which could have been easily explained to any design language. One such issue is RTL (right-to-left) languages, such as Hebrew and Arabic.

HTML supports the dir tag to allow one to easily change from left-oriented design to right-oriented one. In CSS, however, it seems the matter has not been taken into serious consideration. When you have a CSS float, for example, you can choose if it floats left or right but there's no way for you to say something simple like left and left-fixed. IMHO, left should have changed to right on RTL languages while left-fixed would have always kept left. The same goes to specifying the 4 dimensions like in 'padding: 1px 2px 3px 4px;'. They should be switched unless the directive fixed is added.

But since CSS doesn't do that well, a developer from Google has created a python script called CSSJanus which tries to address many issues relevant for converting a CSS from a left-oriented one to a right-oriented one. It's code is available here.

Since Colnect is built using PHP, I've decided to only use a few ideas from the CSSJanus code and integrate them into the JS/CSS combinator already in use. The idea is quite simple, the application asks for a different CSS file when it's right-to-left (RTL) oriented by prefixing some directive to the CSS requested which lets the combinator understand it should add the conversion.

You can start with the combinator script code here.

These two lines at the top of the script will add RTL directive:
$bRTL = (substr($_GET['files'], 0, 4) == 'rtl_');
if ($bRTL) $_GET['files'] = substr($_GET['files'], 4);


Now the cache hash should be different so there's a slight modification here:
$hash = $lastmodified . '-' . md5($_GET['files'].($bRTL ? 'RTL' : ''));


And the last thing to do is to create the left-to-right conversion function and place it just after stripping the CSS comments. Add this:
if ($bRTL) $contents = CssSwitchLeftToRight($contents);


And here's my simple conversion function (that does NOT cover many cases covered by CSSJanus):
/**
* Switch left to right and vice versa for a few of the cases relevant for css
*
* @param string $str
* return string
*/
function CssSwitchLeftToRight($str) {
$arConversionSeq = array(
'/-left/' => 'TOK1',
'/-right/' => '-left',
'/TOK1/' => '-right',
'/float\s*:\s*left/i' => 'TOK2',
'/float\s*:\s*right/i' => 'float:left',
'/TOK2/' => 'float:right',
);
foreach ($arConversionSeq as $pattern => $replacement) {
$str = /*"doing{} $pattern => $replacement ".*/preg_replace($pattern, $replacement, $str);
}
return $str;
}


I have not posted the entire script here since it has site-specific modifications on my site. You're welcomed to comment here if further clarifications are needed.

Link and Search

Did you like reading it? Stay in the loop via RSS. Thanks :)