<?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>sync;sync &#187; On Codes</title>
	<atom:link href="http://andy.sinaptix.com/category/codes/feed/" rel="self" type="application/rss+xml" />
	<link>http://andy.sinaptix.com</link>
	<description>flush the garbage</description>
	<lastBuildDate>Tue, 27 Oct 2009 09:44:52 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.5</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Akelos, Speaking Rails in PHP</title>
		<link>http://andy.sinaptix.com/2007/10/26/akelos-speaking-rails-in-php/</link>
		<comments>http://andy.sinaptix.com/2007/10/26/akelos-speaking-rails-in-php/#comments</comments>
		<pubDate>Thu, 25 Oct 2007 19:34:23 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[MVC]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/10/26/akelos-speaking-rails-in-php/</guid>
		<description><![CDATA[I got stumbled upon ( again ) Akelos, another PHP framework, but this time my short attention span seems didn&#8217;t work   &#8230;
Yeah, it seems mature and stable enough, and maybe because i&#8217;m in process of learning RoR now, that Akelos&#8217; claim of being &#8220;port of RoR in PHP languange&#8221; make more sense than [...]]]></description>
			<content:encoded><![CDATA[<p>I got stumbled upon ( again ) <a href="http://www.akelos.org" title="Akelos Framework" target="_blank">Akelos</a>, another PHP framework, but this time my short attention span seems didn&#8217;t work <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' />  &#8230;</p>
<p>Yeah, it seems mature and stable enough, and maybe because i&#8217;m in process of learning RoR now, that Akelos&#8217; claim of being &#8220;port of RoR in PHP languange&#8221; make more sense than before.</p>
<p>Why am i interested in Akelos ? There are several other PHP frameworks that claim to be &#8220;inspired by&#8221; or &#8220;ports of RoR&#8221; namely CakePHP, CodeIgniter ( inspired ones ) and PHP on Trax ( port ).</p>
<p>I&#8217;ve been using CodeIgniter for a while and like it so far, because it has great documentation, lightweight, and easy to extend, although as many other PHP frameworks, it tends to get hairy if the developer gets too excited or plain too old fashioned to adhere to MVC concept. the lack of automation and claim of being small, lightweight freeform MVC framework in CodeIgniter is likely the cause of such failure to enforce MVC separation and reuseability ( or DRY ). I don&#8217;t blame the creator, actually i like CI very much because it cuts a significant portion of my work on particular project, make everything so fast, and above all, fun.</p>
<p>After i tried Akelos however, i got more excited, because it has the same ease of use of CI, at least in terms of requirements, like it works in PHP4 and PHP5, the package is easy to install, through SVN and downloadable package, and self contained, it doesn&#8217;t get stranded to PEAR ( like PHP on Trax ). Personally i don&#8217;t like PEAR because i&#8217;ve encounter too much trouble setting up on many different kind of machine ( Windows, Linux, and now OS X ).</p>
<p>With the bonus of Rails like automation, like generator, migration, etc. which doesn&#8217;t currently exist in CI, Akelos should be fun to work with, after all , it is a port of Rails. So i think i will take a closer look at it, maybe it could become a good learning tool on Rails concepts. I know PHP for a long time , then it&#8217;s a bit hard to switch lane to Ruby, learning RoR using Akelos should be a logical way to gradually move to pure RoR world.</p>
<p>Mind you, I&#8217;m not into language / framework war, for me it&#8217;s just another language and another framework. I use them accordingly depending on my particular needs, so i don&#8217;t scrap one for another, but i simply put them in my personal toolbox to use any of them as required.</p>
<p>The reason i don&#8217;t pick CakePHP is because it&#8217;s a whole different kind of framework although it has many of good features of RoR ( automation with bake, ORM, etc ). PHP on Trax, hmm, PEAR, so i think i&#8217;ll pass. I pass on other PHP frameworks too because they are PHP5 only, which is not good for the moment since my servers are still running PHP4, although they have great features too.</p>
<p>So, Akelos should be good enough now, although I don&#8217;t think it will match RoR fame, but it will become a fresh breath of air on PHP world, particularly in this moment where PHP gets mocked as inferior than Ruby or Python ( or other languages by fact ). Other thing is I actually like the modest attitude of Bermi Ferrer, Akelos&#8217; creator. DHH is just simply irritating, but i still respect him as a great programmer.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/10/26/akelos-speaking-rails-in-php/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Language Neutral Programmer</title>
		<link>http://andy.sinaptix.com/2007/10/23/language-neutral-programmer/</link>
		<comments>http://andy.sinaptix.com/2007/10/23/language-neutral-programmer/#comments</comments>
		<pubDate>Mon, 22 Oct 2007 20:56:34 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[On Codes]]></category>
		<category><![CDATA[Techno Rants]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/10/23/language-agnostic-programmer/</guid>
		<description><![CDATA[I started to learn Ruby, o yeah !!
why ?  because i can, that&#8217;s why&#8230; okay, okay, because i want to be able to use that oh so great and almighty Ruby on Rails, brother !
Actually, many have advised that you just need a handful of Ruby basic to be able to use Rails, but [...]]]></description>
			<content:encoded><![CDATA[<p>I started to learn Ruby, o yeah !!</p>
<p>why ?  because i can, that&#8217;s why&#8230; okay, okay, because i want to be able to use that oh so great and almighty Ruby on Rails, brother !</p>
<p>Actually, many have advised that you just need a handful of Ruby basic to be able to use Rails, but i think that will be equivalent of having a ten thousands French word traveller dictionary and then fly to Paris.</p>
<p>The bigger picture is that i&#8217;m sick and tired of all those &#8220;mine is better than yours&#8221; attitude when it comes to programming language. I believe that a programming language is no different with natural language. You use it because you need to communicate and furthermore, get things done.period.</p>
<p>I only believe that one language could do specific purpose better than others, but i never believe that there is one ultimate, do-it-all language. I also have preferences, mostly because i need to get things done quickly using language i deem fit for the right job. Hey, why should i write a servlet if all i need is just a simple contact form and mailer ? spare 10 minutes of your busy time and use php, that will do fine.</p>
<p>There&#8217;s a saying : &#8220;Good programmer learn one new programming language every year&#8221;. There&#8217;s nothing more i could agree with. My first language was BASIC, the version for IBM PC-XT, then Pascal as in Turbo Pascal, then a little bit of Assembler, because i think that will be cool if i can directly control PC hardware using it, which i then drop because it brought me more headaches than fun, then a little bit of C/C++, javascript, then PHP, which i find useful to make a living&#8230; I learn a bit on some more exotic language, like Scheme, Haskell, and even Erlang, and &#8230; it&#8217;s like learning Latin, what the hell was i thinking &#8230; I learn and then use Java by force, because i have projects that require it, which is okay, at least i can create nice software for my phone, then came Python, by which then i also learn the beauty aspect of a programming language, and now came Ruby, which is even more beautiful, because it has strong resemblance and logic of natural language, namely English language, a human language, yay !!</p>
<p>No, I&#8217;m not praising Ruby, but the point is, every language has it&#8217;s own strength and weakness. And also depend on your habit and common sense on using them. Human has uncanny ability to adapt, while paradoxically make them averse to changes. Like hitting semicolon in Python and BASIC, or forgot that indentation is a must in Python, i think those are glitches commonly happen in natural human language, of course , syntax is more stringent in programming language, but you see the big picture.</p>
<p>I truly believe that programming language is like natural language, in a sense that every individual programmer has one language the know best, like native language, although they&#8217;re not necessarily like it, because that will be the earliest language they learn to understand the concept of programming. And then came another ( or several other languages ) they learn, and then like to use, because they find it easier to fit their needs, and make their good living nonetheless <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>I strongly encourage learning multiple programming language, just so we know that there&#8217;s no point on &#8220;mine i is better than yours&#8221; attitude. PHP tends to become a mess of spaghetti, we all know that, Perl is arcane and makes me feels old, Java is slow and resource hog, etc, etc&#8230; but also remember, PHP is easy and forgiving, Perl has short list of reserved functions, while having a huge repository of nifty modules ready to be used by anybody around the world. So, I suggest, go out and play, find out about lots more programming languages, from the cryptic one into the most elegant one, and you&#8217;ll see why becoming (programming) language neutral won&#8217;t make you less valuable from the rest of the world. It will only teach you to tap the best of each programming languages, and never the other way around.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/10/23/language-neutral-programmer/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>To Ajax or Not To Ajax</title>
		<link>http://andy.sinaptix.com/2007/08/26/to-ajax-or-not-to-ajax/</link>
		<comments>http://andy.sinaptix.com/2007/08/26/to-ajax-or-not-to-ajax/#comments</comments>
		<pubDate>Sat, 25 Aug 2007 18:04:43 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[On Codes]]></category>
		<category><![CDATA[Techno Rants]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/08/26/to-ajax-or-not-to-ajax/</guid>
		<description><![CDATA[AJAX is the current buzzword these days&#8230; no doubt about that. To learn to program AJAX, is like mall roaming teenagers trying to get the latest piece of accessories to make them look hip and cool&#8230; That is, as there is nothing really cool about the piece of stuff, but you will look cool wearing [...]]]></description>
			<content:encoded><![CDATA[<p>AJAX is the current buzzword these days&#8230; no doubt about that. To learn to program AJAX, is like mall roaming teenagers trying to get the latest piece of accessories to make them look hip and cool&#8230; That is, as there is nothing really cool about the piece of stuff, but you will look cool wearing it because everybody will say so&#8230;</p>
<p>No different with AJAX, since there is nothing new in the technology, just good old Javascript plus some ingenuity on using dormant browser feature, then you get a whole new buzzword, which in turn, if you can do it well enough, will raise your self esteem among your fellow programmers, or maybe raise in salary or fee since now you can say &#8220;I can do AJAX too&#8221; to you boss or your client.</p>
<p>From user perpective, no one cares&#8230; all user see is that now they can click on your website and the information pops up quickly, without having to wait for the page to reload. What does it mean for them ? You may say, better user experience. But, be aware, user comes from all walk of life, meaning, they access your site using many different kind of browsers, devices, and don&#8217;t forget, many different levels of infrastructure capacity and capability.</p>
<p>Internet users still varies greatly these days, even with all broadband, wireless whatever technologies.. major portion of the world is still using dial up, yes it is true, and believe it or not, old OS like Win95 is still alive in many many places, meaning IE5 is still around ( yeah, bad enough to have IE around, let alone the old one )</p>
<p>I&#8217;m not exaggerating things here, because this is what happen in my country. I once had a shocked overseas client when I told him I had to switch to dial up connection because he broadband connection went down.</p>
<p>Ok, regarding the title above, in my opinion, a good developer should be aware of everything above mentioned. Developers rarely concern about accesibility, many of us simply trying to create &#8220;cool&#8221; stuff, create the next Facebook, or Google, or WhateverCoolToday sites, then after that wonders, why there&#8217;s only a few people visiting, let alone registering and become returning user ? When that day comes, look back at your codes, don&#8217;t look at marketing people, at least, recheck your codes before you throw flames at marketing <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>What does these have anything to do with AJAX ? AJAX is cool , and it provide better user experience isn&#8217;t it ? Hmmm&#8230; AJAX put more strain to the server than ever before. that&#8217;s one for a start. Back in the days, a hit means one user accessing one url, or one web page, if she stays for 10 minutes on the same page, doesn&#8217;t really matter because no request sent to server during that 10 minutes ( well sort of &#8230;). These days, take example of a page with autoupdating AJAX widget, when a user access it , read that page for the same 10 minutes, she wouldn&#8217;t even realize that during that 10 minutes of her visit, her browser has sent hundreds of request, AJAX request or XHR if you prefer geekier term. Put more variables into the situation, let&#8217;s say, her PC is a rather old Pentium 3 laptop, with bundled Windows2000 and yet to be upgraded IE5.5 &#8230; She connect to the internet using 50kbps residential shared broadband connection, on peak hour which only give her only a portion of the term &#8220;broadband&#8221;&#8230; chances are she won&#8217;t even stay for 10 minutes, but if she survived, then that will become a strain on her PC too.</p>
<p>Think about this when developing web application in general, not just when being cool developing AJAX. Good developer do test, meaning, not just testing for the functionality and reducing bugs, but also test in every condition possible. Remember, you develop for user, not just for your personal enjoyment ( but if that the case, then good for you, you may scrap all my blurb here ). In my experience, you can throw anything you want to the user, they will grab it instantly, but on the other hand, they are smart enough not to swallow everything, and when it happens, they simply move on and forget about your site entirely.</p>
<p>Other thing is mash ups and APIs&#8230; I personally like the concept of sharing with the world for the better, but I never understand how one can build a business out of somebody else&#8217;s application API. How realiable could it be for the user ? Fine if the API come from Yahoo, Google or the glorious Facebook, but what about so many more that provides API because they want their application to grow bigger, not because they think their application is usable, unique and people really demand API to get connected ? reliability is the main concern here. Just take example of pre Ajax mash ups, the banner exchange&#8230; nothing too smart about exchanging banner, but when a website has too many different affiliates, with different infrastructures, and different server loads, it will become hell for the user because pages will load with random and somewhat significant speed difference, and hell for the developer to figure out which affiliate link cause the problem. Things get worst when banner exchange start to use javascript, which is NOT threaded, therefore, it will be executed in blocking sequence, and once it stuck on one affiliate code, it will attemp to finish that block of code first before moving on to another block. If it stuck forever, you&#8217;ll get crashed browser, or simply half complete page staring at you.</p>
<p>Okay, no worry.. I do believe in progress, and I also believe that technology will solve it&#8217;s own problem, but in the mean time, there&#8217;s nothing wrong with becoming developer with conscience. A developer with good understanding on what user will need and use, rather than developing something too advanced and too sophisticated that will defeat it&#8217;s own usability.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/08/26/to-ajax-or-not-to-ajax/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Username as Subdomain in Codeigniter a.k.a Wildcard Subdomain</title>
		<link>http://andy.sinaptix.com/2007/08/22/username-as-subdomain-in-codeigniter/</link>
		<comments>http://andy.sinaptix.com/2007/08/22/username-as-subdomain-in-codeigniter/#comments</comments>
		<pubDate>Wed, 22 Aug 2007 14:53:21 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[On Codes]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/08/22/username-as-subdomain-in-codeigniter/</guid>
		<description><![CDATA[I&#8217;ve been wondering for a while if I can do automatic subdomain using username, same as Wordpress MU does. Some thought come across and all leads to same point , the $base_url() variable.
What makes me a bit wary is that particular variable reside in config file, which suppose to be static. On the other hand, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been wondering for a while if I can do automatic subdomain using username, same as Wordpress MU does. Some thought come across and all leads to same point , the <code>$base_url()</code> variable.</p>
<p>What makes me a bit wary is that particular variable reside in config file, which suppose to be static. On the other hand, manipulating the variable in controller is easy but redundant. So what the heck&#8230;<br />
There are three places to modify for this :</p>
<ol>
<li> DNS entry</li>
<li> Apache vhost</li>
<li> Codeigniter config.php</li>
</ol>
<p>Life has been good to me since I have full control over those three, I have my own DNS server, and apache server, so if you are less fortunate than I am, do not hesitate to nag , beg and annoy your hosting company to do changes for you</p>
<p><strong>DNS entry :<br />
</strong><br />
make sure you put wildcard entry :<br />
<code>mygreatsite.com.           A       123.123.123.001<br />
*.mygreatsite.com.        A       123.123.123.001</code><br />
<strong> Apache vhost :<br />
</strong><br />
We use separate vhost file for each domain, and include those files using Apache &#8220;Include&#8221; directive, to keep things tidy and avoid fiddling with main apache config.<br />
<code>&lt;virtualhost&gt;<br />
ServerName mygreatsite.com<br />
ServerAlias *.mygreatsite.com<br />
ServerAdmin superduperadmin@superduperwebcompany.com<br />
#RedirectMatch 301 (.*) http://mygreatsite.com$1<br />
DocumentRoot /var/oi/keepcodeigniterhere<br />
&lt;directory&gt;<br />
Options Indexes FollowSymLinks MultiViews<br />
&lt;/directory&gt;<br />
AllowOverride All<br />
Order allow,deny<br />
allow from all<br />
&lt;/virtualhost&gt;<br />
</code><br />
the most important part is :<br />
<code> #RedirectMatch 301 (.*) http://mygreatsite.com$1</code><br />
<strong>CodeIgniter config.php :</strong></p>
<p>I test using this simple hack ( on the config.php ) :<br />
<code> $config['base_url']     = "http://".$_SERVER["HTTP_HOST"];<br />
</code><br />
And wala !! I can test using whatever.mygreatsite.com and codeigniter still working as if there is nothing wrong with <code>$base_url</code> variable, therefore you can use any words ( hence, wildcard ) as subdomain prefix and apache will direct the request to the same codeigniter installation. Next step I will do is using username as subdomain, eliminating ugly url like<br />
<code>http://www.mygreatsite.com/someuser/profile</code><br />
and make it nicer as in<br />
<code>http://someuser.mygreatsite.com/profile</code><br />
Nice !!<br />
Yeah I know I have to test rigorously to ensure nothing is broken with codeigniter ( and my application ) but at this moment I think it leads to the right direction.<br />
I also do some search at CodeIgniter&#8217;s forum just to verify my method and I&#8217;ve found great reference :<br />
<a href="http://codeigniter.com/forums/viewthread/51627/">http://codeigniter.com/forums/viewthread/51627/</a></p>
<p>For wildcard DNS, take a look at this guide by Wordpress creator :<br />
<a href="http://photomatt.net/2003/10/10/wildcard-dns-and-sub-domains/">http://photomatt.net/2003/10/10/wildcard-dns-and-sub-domains/</a></p>
<p>from those forum entry, I&#8217;ve made final modification to the config.php file :<br />
<code>$config['base_url']     = "http://".$_SERVER["HTTP_HOST"];<br />
// provide easy to access variables for the rest of the application<br />
$usernamehost = explode('.', $_SERVER['HTTP_HOST'], 2);<br />
$config['tld_base_url'] =  $usernamehost[1]; // contains "domain.com"<br />
$config['user_base_url'] = $usernamehost[0]; // contains "sub"<br />
</code><br />
Hopefully this will work as expected , and also useful to anybody who wants to achieve similar thing.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/08/22/username-as-subdomain-in-codeigniter/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>10 Thing A Web Developer Should Have or Do</title>
		<link>http://andy.sinaptix.com/2007/08/04/10-thing-a-web-developer-should-have-or-do/</link>
		<comments>http://andy.sinaptix.com/2007/08/04/10-thing-a-web-developer-should-have-or-do/#comments</comments>
		<pubDate>Fri, 03 Aug 2007 18:54:17 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[On Codes]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/08/04/10-thing-a-web-developer-should-have-or-do/</guid>
		<description><![CDATA[Just a twitch in my brain :

know basic HTML&#8230; seriously  
have Firefox browser, the (most) standard compliant browser whatever that standard is ( actually i don&#8217;t really care about standard, it works for me as long it looks good on any browser ), always develop using this, then test on the rest of  [...]]]></description>
			<content:encoded><![CDATA[<p>Just a twitch in my brain :</p>
<ol>
<li>know basic HTML&#8230; seriously <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
<li>have Firefox browser, the (most) standard compliant browser whatever that standard is ( actually i don&#8217;t really care about standard, it works for me as long it looks good on any browser ), always develop using this, then test on the rest of  bunch, namely IE, Opera and Safari, and don&#8217;t forget your phone browser, which is more or less having the same base with Safari ( Webkit )</li>
<li>have Firebug extension for Firefox, save a lot of trouble on debugging, CSS, Javascript, AJAX</li>
<li>have a good text editor, not Notepad, use serious one designed for programmer like UltraEdit, Crimson ( Win ), TextMate ( Mac ), or vim, geany, bluefish ( Linux )</li>
<li>can edit (X)HTML using number 4, not using brain-killing-WYSIWIG-tools like Dreamweaver, so that is why knowledge on number 1 is a must.</li>
<li>know CSS. Yeah, sometime great design can be produced without table and image.</li>
<li>know how to program Javascripts</li>
<li>can program at least in one of popular server side language, namely Java, PHP, Python, ASP (ick..), ability to use frameworks also helps, just pick one, Ruby on Rails, CakePHP, CodeIgniter, Prado, Django, Turbogears, Pylon, and so on, and so on. Knowledge on SQL also mandatory if working with database.</li>
<li> know how to put all those above together and produce good looking and usable website ( must be both not just pick one ), meaning, it must be clean, clear for user, optimized for viewing on any platform, even any device, through any bandwith&#8230; such a heavy undertaking eh.. oh yes, it must be clean from error messages and bulletproof from any possible hacks.</li>
<li>have sex regularly , heheh, well at least once in a while&#8230; to clear up all those dirty xhtml, css tags and program errors from your brain&#8230; come on, no matter how cool a website you can produce , nobody really cares about who creates the good stuff. So get a life, have fun in real world, get a real good stuff for yourself.</li>
<li>that&#8217;s it I think <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/08/04/10-thing-a-web-developer-should-have-or-do/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Getting Around with MVC Framework</title>
		<link>http://andy.sinaptix.com/2007/07/30/getting-around-with-mvc-framework/</link>
		<comments>http://andy.sinaptix.com/2007/07/30/getting-around-with-mvc-framework/#comments</comments>
		<pubDate>Sun, 29 Jul 2007 18:53:18 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[J2ME]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/07/30/getting-around-with-mvc-framework/</guid>
		<description><![CDATA[I&#8217;ve been using MVC frameworks for a while now, and it makes me think why I didn&#8217;t use it earlier&#8230; Yeah, back when I started learn programming I was exposed to procedural way of thinking, remember BASIC on IBM XT ( Yup, I wrote my first program on those awkward looking beige box from IBM, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been using MVC frameworks for a while now, and it makes me think why I didn&#8217;t use it earlier&#8230; Yeah, back when I started learn programming I was exposed to procedural way of thinking, remember BASIC on IBM XT ( Yup, I wrote my first program on those awkward looking beige box from IBM, with amber monitor and glorious Hercules graphic card  ), and that&#8217;s already called a luxurious home PC, considering that at the time, my sister work involving boxes of punched cards and magnetic tapes <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Ok, back to MVC, I&#8217;m not going to do another framework comparison here, rather, just a story about my learning experience&#8230;</p>
<p>My first encounter with MVC was using Java, learning to program desktop application using Swing and AWT, pretty enlightening experience, but i dropped it somehow because I have no real use for it, let alone any project to work on using it&#8230; then came J2ME, when I really have fun with, creating interesting stuff for mobile devices. I also learn a lot about object oriented programming concept here, another interesting stuf, tightly related to MVC.</p>
<p>Now, so many MVC frameworks pops up, it&#8217;s confusing &#8230; all popular programming languages have at least one implementation of it as a framework, notably Ruby on Rails,  Python&#8217;s Django &amp; Turbogears, PHP&#8217;s Prado, CakePHP, CodeIgniter, and many others&#8230;</p>
<p>Which one do I use ? I tried not to get stuck and become single minded on a framework, since in my perspective, all is just tools to get things done. Currently I use CodeIgniter for my project, while I also use Django to learn Python. Why, because CodeIgniter seems to be easiest to learn, and have certain tolerance to my lazy and messy programming practice <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> , tried CakePHP once, and I was lost in convention of plural singular naming&#8230; I notice Django has similar idiosyncracies, but I think I&#8217;m a bit more ready for it , after all, it&#8217;s in different language so everything is new ( I think it&#8217;s just me, it is hard to do things on convention, while I already get used to the way PHP done stuff, free and very tolerance to any kind of programming style )</p>
<p>Beware though, for those who just want to start learn programming, jumping into a framework to learn the language ( and learn programming in general ), is not recommended practice. I suggest learning from the very basic, the very fundamental concept like what is programming, what is procedural, OOP, functional programming, and so on. Otherwise, learning using a framework is like signing up to a flying school to learn to fly, but jump direct into the cockpit of a 747 to learn the &#8220;basic&#8221; of flying and being a pilot.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/07/30/getting-around-with-mvc-framework/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Switch to The Mac</title>
		<link>http://andy.sinaptix.com/2007/07/19/switch-to-the-mac/</link>
		<comments>http://andy.sinaptix.com/2007/07/19/switch-to-the-mac/#comments</comments>
		<pubDate>Thu, 19 Jul 2007 15:45:40 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[On Codes]]></category>
		<category><![CDATA[Random Rants]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/07/19/switch-to-the-mac/</guid>
		<description><![CDATA[Well, I&#8217;ll be a bit lazy and uncreative here, I saw an interesting one here :
How to Switch to the Mac at The Tao of Mac site.
I&#8217;m not going to start any platform comparison, but simply, article above should give a good insight before buying a mac. I switch to Mac for about 2 months [...]]]></description>
			<content:encoded><![CDATA[<p>Well, I&#8217;ll be a bit lazy and uncreative here, I saw an interesting one here :<br />
<a href="http://the.taoofmac.com/space/HOWTO/Switch%20To%20The%20Mac">How to Switch to the Mac</a> at The Tao of Mac site.</p>
<p>I&#8217;m not going to start any platform comparison, but simply, article above should give a good insight before buying a mac. I switch to Mac for about 2 months now, and I regret I didn&#8217;t see this article beforehand.  Not that I will drop my decision to switch if I did, but at least I didn&#8217;t have to learn some things the hard way.</p>
<p>IMHO, Mac is a great platform, I should say, way more than Windows, but less real power than UNIX / Linux. Of course I am biased, I see everything from developer standpoint, I don&#8217;t really care about how nice iPhoto could do photo album, or about downloading music from iTunes ( I wonder, how are those people listen to their 50.000 songs collection ? ).  After all, I pick Mac because :</p>
<ol>
<li>Now it&#8217;s Intel based</li>
<li>OS X is basically UNIX, with less security headache, spyware and myriad of malware lurking to get in.</li>
<li>From price performance ratio standpoint, it&#8217;s very much worthwhile to spend a thousand buck for it, since I can get nice looking, dual core Intel system, that comes with neatly organized OS that I can use right out of the box. I reckon similarly configured Windows laptop will cost around US$ 1500, if ever it match a Mac, at all.. I don&#8217;t know how much a Windows Vista license cost, as if I ever really care <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </li>
</ol>
<p>What I find a bit annoying about Mac is :</p>
<p>copying folder on top of similarly named folder will <strong>overwrite</strong> the old folder, <strong>not merge</strong> into it. I learn the hard way about it, I move a java source package into /opt directory, and all I see later on is a glob of data file named opt in the root directory&#8230; Yaiks&#8230; of course I&#8217;ve done that in terminal using command line ( for those asking &#8220;How come&#8230;&#8221; ), move a file is the same with renaming a file in UNIX world, and in my head &#8220;mv somefile.tar.gz /somedir&#8221; usually move the file into the directory, not renaming the file and overwrite the directory, the operating system should be able to distinguish the type of the target, whether it&#8217;s a regular file or a directory&#8230; pretty much a brain dead way on doing simple thing, especially for highly praised and overhyped platform &#8230; sigh..</p>
<p>I know, i know, there&#8217;s a warning when you do sort of thing, but mind you, I was doing it in the shell terminal, not in Finder GUI, anyway, I still think that Mac OS should be able to merge folders, or at least distinguish between regular file and directory and then act accordingly, not just giving stupid useless warning telling that user is stupid on attempting such action.</p>
<p>Other thing is the warning on &#8220;leaving a secure website&#8221; which only have one button &#8220;OK&#8221;, hmm.. oh no, that&#8217;s for other stuff, not Mac OS .. haha <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/07/19/switch-to-the-mac/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Social Network In Techno Tongue</title>
		<link>http://andy.sinaptix.com/2007/07/15/social-network-in-techno-tongue/</link>
		<comments>http://andy.sinaptix.com/2007/07/15/social-network-in-techno-tongue/#comments</comments>
		<pubDate>Sat, 14 Jul 2007 18:43:56 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[CMS]]></category>
		<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[On Codes]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/07/15/social-network-in-techno-tongue/</guid>
		<description><![CDATA[I&#8217;ve been working on a social networking site for a while now, and here&#8217;s some basic concept I&#8217;ve learn from he process ( warning : These are based on my experience, maybe different with you, but what do i care&#8230; ) :
Basic Entity of a Social Network Site :

User ( could be Person or anything [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been working on a social networking site for a while now, and here&#8217;s some basic concept I&#8217;ve learn from he process ( warning : These are based on my experience, maybe different with you, but what do i care&#8230; ) :</p>
<p>Basic Entity of a Social Network Site :</p>
<ol>
<li>User ( could be Person or anything else, think about social network for your pet )</li>
<li>Message</li>
<li>File</li>
</ol>
<p>Expecting something more ? well, I tell you, nothing more than these I can tell you about <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /><br />
Anything else is built on top of those entities as extension, or simply connecting those three, in meaningful way of course.</p>
<p>Example :</p>
<ul>
<li>User connected to other User as friend</li>
<li>User send Message to other User, to her / his friends, or simply make it available to public</li>
<li>A File attached to a Message sent from one User to another.</li>
<li>User make a mark ( a tag , for you pundits ) to a File, then send Message to other user about it.</li>
<li>User make comment on other User&#8217;s Message with a File attached to it, a comment itself is another form of Message</li>
</ul>
<p>Think about it, we can create so many other kind of  relationship between those three objects, tangle it, twist it, of course it has to be in meaningful way, and then you got your social networking site, as simple as that, in a geek point of view.</p>
<p>So far, with all these basic knowledge about those three basic entities, I have abandon one CMS system ( Drupal, sorry for all you Drupal fans out there&#8230; ) because I then realize that generic CMS can only accomodate the relationship the way it want me to, not the way I want it to, well, maybe because I have insufficient knowledge for the CMS, or maybe I just mess around too much with it, I don&#8217;t know&#8230; All I know is that I can&#8217;t get scalability and speed by just plugging around all different add-on modules created by all different people and way of thinking and then try to configure smoothly as if it was all come from same people.  It was simply hard to imagine how to scale up, if early in development phase you already have at least 40 tables in the default database ( yaiksss&#8230; ), not to mention the way add-on, modules, and hooks works&#8230; with more than 20 modules installed, a simple process like saving a node will take significant time since the system will have to enquire which hook implementation should be triggered, and amny other part of the system need to be triggered to keep everything in sync.</p>
<p>I tell you, it was like fishing with a shot gun&#8230; really, you are on boat, aiming for a fish with your shot gun, fire up, and then &#8230; the thundering sound will drive away the fish , along with everything else that can move, and the shot gun kick back will send you off the boat on the other direction <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  &#8230; not good, not good&#8230;</p>
<p>I move on rewriting the whole thing, using CodeIgniter, a sleek simple MVC based PHP framework, and so far I get by with only 15 tables in my database to carry all the data required by those 3 basic entities, including all the relationships between them, not a bad setup, as I expect I will end up with less than 20 tables when the site will be launched.</p>
<p>Okay, I admit, I do a great deal of denormalization, because I need speed and less query, the wisdom came from my mobile content days&#8230; And I also feel sick about table joins, so I&#8217;d rather make the DBAs and business application programmers disappointed, than make my life less joyful, couldn&#8217;t care less about their feelings anyway, if you ask me&#8230; After all, theory is good, but when you have to face real world, all you can think of is how to get there in simplest, fastest way possible.</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/07/15/social-network-in-techno-tongue/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>The Joy ( and Horror ) of CMS</title>
		<link>http://andy.sinaptix.com/2007/07/06/the-joy-and-horror-of-cms/</link>
		<comments>http://andy.sinaptix.com/2007/07/06/the-joy-and-horror-of-cms/#comments</comments>
		<pubDate>Thu, 05 Jul 2007 18:32:22 +0000</pubDate>
		<dc:creator>Andy Awidarto</dc:creator>
				<category><![CDATA[CMS]]></category>

		<guid isPermaLink="false">http://andy.sinaptix.com/2007/07/06/the-joy-and-horror-of-cms/</guid>
		<description><![CDATA[After several times dealing with major open source CMS ( Mambo, Joomla, Drupal, WordPress ), I have developed certain wisdom over the matter in a holistic ( pvuwaah !!  ) ) approach.
Well, NOT&#8230;  haha
Okay, seriously&#8230; in my point of view now, a CMS is a rigid blob of code, needed to be hacked, [...]]]></description>
			<content:encoded><![CDATA[<p>After several times dealing with major open source CMS ( Mambo, Joomla, Drupal, WordPress ), I have developed certain wisdom over the matter in a holistic ( pvuwaah !! <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> ) ) approach.</p>
<p>Well, NOT&#8230;  haha</p>
<p>Okay, seriously&#8230; in my point of view now, a CMS is a rigid blob of code, needed to be hacked, tweaked, whipped hard like a mule, just to get it working the way you want it to, that is manage your content&#8230;</p>
<p>Yes, true that they are designed to ease the development process, especially when you don&#8217;t have that much resources around. A web designer could use Joomla for example , to have a dynamic website up and running in matter of days from scratch, but that&#8217;s just a plain good website taking its content from database, plus some some plugins and add on stuck all over it just to get client eat the eye candy happily&#8230;</p>
<p>The fact is, after the final payment, the designer going home happy, while the horror for the client has just began &#8230; CMS usually designed to be general purpose, therefore many things are just unnecessary bloat&#8230;  to make it flexible, the developer usually compromise on many thing, like deliberately unoptimized query&#8230; why it&#8217;s not optimized ? because it is necessary to be unoptimized&#8230; otherwise no way to get things done, not necessarily done gracefully, but just done. period.</p>
<p>My latest experience is with Drupal&#8230; a CMS with great review, popularity, and a horde of fanatical fans&#8230; how am I doing with it ? I tell you, my first impression is great, it&#8217;s slim ( just under 400kb of source script ) , easy install, no nonsense administrative panel, multiple site with one installation, possibility to make sigle sign on for multiple site, etc.</p>
<p>The &#8220;community plumbing&#8221; motto sounds good, the plug in architecture is nice, user management is just about everything you need&#8230; but then comes the horror&#8230; what i needed to for the site i developed is a full featured media management system, that is a system that is capable to handle video, audio, and image, plus i have to develop certain degree of social network and commerce function on top of it. I tried all available add on , plug &#8216;em in, configure, tweak&#8230; no use&#8230; everything just plain messy, disintegrated, and worst, it force user ( and me as developer ) to think the way Drupal ( or its developer ) think. The ugly magic showed up, weird stuff popping up here an there&#8230; just like you are on a boat in the middle of a lake, where the boat turn out to be a wreck because the shiny paint that looks great on shore , simply dissolve in the water, revealing horrific holes and ugly creaking patches.</p>
<p>okay, enough with the horror story, the thing is that after grinding my brain on moving things in Drupal molasses, I just fed up and swallow the fact that it&#8217;s just only good for prototype, a proof of concept. I wouldn&#8217;t even bother to imagine using it for real production site, which will handle thousands of concurrent user every second. It just won&#8217;t stand it.</p>
<p>Now, back to square one&#8230; well not entirely, i got the whole plan mapped out and all pitfalls and bewares noted from the proto site. All i need to do now is to rewrite the whole thing nearly from scratch, using lower level library and framework. that way I know what&#8217;s under the hood, as I&#8217;m the one writing it, i know the kinks and bends as i created them <img src='http://andy.sinaptix.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>So&#8230; don&#8217;t get too excited with CMS, my good friend&#8230; it could only get you that far, but never beyond&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://andy.sinaptix.com/2007/07/06/the-joy-and-horror-of-cms/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
