About Ryan

I am a software engineer with 5+ years of well-rounded experience. I have built numerous web applications, architected an MVC framework, designed and built website's frontend and backend infrastructure. I have also an experience in e-commerce and information retrieval systems. I can work with most major OS, database and development platforms.

Ubuntu 10.04 (Lucid Lynx) Installation Problems: No partition, dmraid library error and blank installation window

First of all, kudos to all the guys behind Ubuntu distribution from the maintainers, committers, developers and to all those people that made this release (10.04) possible. The Ubuntu 10.04 (Lucid Lynx) is a kick-ass release! Effin insane boot-time!

Now lets go back to the problem which I’ve encountered first hand during installation and after the installation process. There’s three(3) actually, so I’m gonna go through each and every one of them but the solution is quite simple:

Problem #1: No partition found

I have Windows 7 installed on my hard drive but I planned to replace it with Ubuntu and use the entire disk (totally wiping out the Windows partition). But when I get to the “Prepare partitions” window, I see no partition. If you encountered this problem, here’s what you do:

  1. Click the “Back” button (It’ll take you back to the “Keyboard layout” window)
  2. Once you’re in the “Keyboard layout” window, Press “Ctrl + Alt + F1” to go to terminal mode.
  3. (On terminal mode) Type-in “sudo apt-get remove dmraid” then hit “Enter” key. (Ignore any error that you see cause it’ll not matter)

  4. Return to GUI mode by pressing “Ctrl + Alt + F7”, now you may continue on with the installation process.

The problem is due to Dmraid (fake raid) is active by default and are supported out-of-the-bot on the Ubuntu 10.04 LTS Desktop CD.

Problem #2: dmraid shared libraries loading problem on boot startup

Now this problem is I think caused by the solution made for the previous problem (Problem #1).
I think it didn’t entirely remove the reference to dmraid, so it is still trying to load the dmraid libraries on boot-time. On boot-time (before the splash screen) you’ll get a nasty error, saying:

dmraid: error while loading shared libraries...

Now the solution to that is removing the dmraid support entirely. Here’s what you need to do:

  1. Once Ubuntu desktop is loaded, open a “Terminal” (Accessories → Terminal).
  2. On terminal window, type-in “sudo apt-get remove dmraid” and hit “Enter” key.
  3. After removing dmraid, restart your PC (soft reboot).

There you have it! Problem solved.

Problem #3: Blank window or no “Welcome” window

I’ve booted the installation CD on my laptop but after the loading part it popups a blank window and no options were shown. So obviously I cannot continue with the installation. But after a few trial and error , I’ve finally found a solution to get the installation window to work (show the installation options).

Here’s the solution:

  1. Boot from CD and when it starts on booting press “F6” key to go to the boot installation options (live CD, disc check, memory test, language, accessibility, etc).
  2. When you get to the installation option screen, press “F6” for “Other Options” (boot options).
  3. Select “nomodeset” by using the arrow key and pressing the “Enter” key to mark it.
  4. Press “Esc” key and continue with the installation by choosing “Install Ubuntu” and then pressing the “Enter” key.

That’s it. I hope the solutions given above helps.

Cheers!

A connection attempt failed because the connected party did not properly respond

If you’re like me, using EasyPHP on Windows 7 for local development and have encountered this PHP/MySQL error:

Warning: mysql_connect() [function.mysql-connect]: [2002]
A connection attempt failed because the connected party did
not (trying to connect via tcp://localhost:3306) in
C:\Path\To\Script.php on line 26

Warning: mysql_connect() [function.mysql-connect]: A connection
attempt failed because the connected party did not properly
respond after a period of time, or established connection failed
because connected host has failed to respond. in
C:\Path\To\Script.php on line 26

Fatal error: Maximum execution time of 30 seconds exceeded in
C:\Path\To\Script.php on line 26

..then you’re in luck! Here’s a quick easy fix:

  1. Go to “C:\Windows\System32\drivers\etc“.
  2. Open “hosts” with Notepad program.
  3. Uncomment this line: “127.0.0.1 localhost” or add it if it’s not on the host entry.

That’s it! Save the changes you’ve made and refresh your browser.

Hope this helps!

* NOTE – Make sure you have a full access on “hosts” file.

  1. Right click on “hosts” file then click “Properties“.
  2. On “Security” tab click “Edit…” button.
  3. Select the user that you are currently using.
  4. Under “Permissions for Users” box, tick “Full control” on “Allow” column.
  5. And then click “OK” button to apply the changes.

jixedbar: A stick or die jQuery plugin (jstcky Redux)

I just recently released a new OSS project called jixedbar, a jQuery plugin that stick/fix a Div element on the bottom of a page/website. Inspired by Facebook’s fixed app/menu bar, the code is based on the jstcky (deprecated project) but with improved codebase, features, and written as a jQuery plugin to maximize the use of jQuery’s rich features.

Here’s a quick demo: http://ryan.rawswift.com/sandbox/jixedbar-0.0.2/demo/

You can get the Beta release from Google Code Project Host, either by downloading the archive file or through Subversion (SVN) repository.

Send your comments and suggestions to rawswift at gmai dot com.

Cheers!

EasyPHP on 64 bit Windows 7: How to fix Apache and MySQL problem

EasyPHP on Windows 7

EasyPHP on Windows 7


Apache

I am accustomed in using EasyPHP on a Windows platform. Installation, running, and configuring it is always a breeze (on Windows XP that is). Recently I’ve installed Windows 7 RTM on my MSI notebook and installed EasyPHP 5.3.0, though the Installation goes flawlessly but then when I launch the stack software, Apache wouldn’t start.

I turned off the firewall but no luck. So I did a search on google, again no luck with Windows 7 specific solution but I found one for Windows Vista. I tried it anyway, then BAM! It worked! I finally got Apache to start, tried opening the local default web and it worked perfectly. Here’s the error message and how to fix it:

Apache cannot be runned: another Web server use the Web port
or port is blocked by firewall.
  1. Click the EasyPHP icon beside “Apache” button.
  2. Click “Configure” then click “EasyPHP“.
  3. Uncheck “Check server’s TCP port before starting” then click “Apply” button and then “Close” button.
  4. Click “Apache” button and then click “Start“.

That would fix the “Apache cannot be runned…” problem.

MySQL

Got the Apache server to work but after I closed EasyPHP and run it again, I’m hit with another error message:

Unexpected end of MySql... See log file?

Now it’s from MySQL. After a few head scratching and inspection. And then it hit me! I figure that must be a permission problem. So I changed my user’s permission for the EasyPHP directory and Viola! MySQL finally start. Solved the MySQL problem. Here’s what I did:

  1. Go to “Computer“, open/view Drive C, then double click “Program Files (x86)“.
  2. Right click on “EasyPHP5.3.0” folder then click “Properties“.
  3. On “Security” tab click “Edit…” button.
  4. Select the user that you are currently using.
  5. Under “Permissions for Users” box, tick “Full control” on “Allow” column.
  6. And then click “OK” button to apply the changes.

Now you’ll be able to start MySQL server by clicking “MySQL” button on EasyPHP dialog and then click “Start“.

Hope this helps!

MSI CR400: The new “Classic” series

Yesterday, I bought my new shiny notebook to replace my old one. It’s an MSI CR400. Its the first in a new series called “Classic”. It’s a 14-inch elegant looking notebook with Intel Core 2 Duo processor, NVIDIA GeForce video card, 4GB memory, and comes with 250GB SATA hard drive. Bought it for just 29,999.00 Php ($624.99).

Here’s the complete spec of my notebook:

Operation System No OS
Processor Intel Core 2 Duo processor (T6500 2.1GHz)
Chipset nVidia MCP79MVL
LCD 14″ HD Ready 16:9, 1366×768 LED Backlight Display
Video GeForce 8200M G, VRAM is shared with system memory
Memory 4GB DDR2 800Mhz (Maxed 2 slot)
Audio Speaker 2
Webcam 1.3 M Webcam
Communication LAN 10/100 LAN
Wireless LAN 802.11 b/g/n
I/O Card reader 4 in 1 (support SD,MMC,MS,XD)
Mic-in/Headphone out 1/1
USB 2.0 3
RJ45 1
D-Sub 1
Storage 250GB SATA HDD (2.5″ form factor)
Optical Drive DVD Super-Multi
Battery 6 Cells
Keyboard 87 keys
Power AC Adapter 65W
Dimension 344.4x 212 x 13.5.-28mm
Full System Weight 2kg (With 6 Cell Battery)

Loaded it up with Ubuntu 9.04 (jaunty jackalope).

MSI CR400 "Classic"

Aptana: How to enable PHP Code Assist

If you are a PHP developer, you know that code refactor, code completion, and code assist is a very essential features that you’ll want to have on an IDE and Adobe’s Dreamweaver couldn’t give that to you. Don’t get me wrong, I love Dreamweaver, actually I’m still using it (on my Windows desktop) for HTML and web design mockups and it’s still one of the best HTML editor out there but that’s about it, an HTML editor, nothing more.

Have you ever tried Aptana? Well you should! If you’re a Web developer, building the next biggest, greatest, and newest application of the future then Aptana will be a great tool for you. It has code refactor, PHP code completion, code assist, FTP, SFTP, and SSH support and it’s FREE (Aptana Community Edition)! Plus it also has support for Ruby (Rails), Python, Adobe Air, and other language or platform. But wait there’s more! Ajax libraries (jQuery, Prototype/Scriptaculous, Adobe Spry, Dojo, etc). And if you’re a code version control freak, no worries! It has CVS, Subversion, or Git plugin support.

Enough with the promotion! Cause I will not get paid even doing so. But if you want an IDE with tons of support and features then Aptana is one of the best out there. Especially their code assist feature, it’s a top-notch. Aptana’s code completion for PHP’s common methods are default, you’ll have to install PHP plugin first to get this feature and for Aptana to recognize PHP codes and files.

To enable PHP Code Assist in Aptana, follow the simple instructions below. This will be useful if you have classes and methods that you want to be visible all over your project.

Code Assist will only work locally which means your source file must be in your local drive (not on a remote). But there’s a workaround for this, and we’ll get to that later on.

This is how to enable PHP Code Assist:

Local Projects

  1. Click “Project” tab (found on the left panel of Aptana environment).
  2. Create a new project (right click, New -> Project…).
  3. (on New Project window, under Aptana Projects) Select “PHP Project“.
  4. Click “Next” button, type in your project name then click “Finish” button.
  5. Select and right click on the newly created project and click on “Properties“.
  6. Select “Project Natures“.
  7. Tick “com.aptana.ide.editor.php.phpnature (PHP Nature)“.
  8. Then click “Ok” button.

Remote Projects

If your working with remote files (remote server or hosted site) then steps are different but almost similar to the above.

  1. Click “Project” tab (found on the left panel of Aptana environment).
  2. Create a new project (right click, New -> Project…).
  3. (on New Project window, under Aptana Projects) Select “Existing Hosted Site“.
  4. Click “Next” button, type in your project name then click “Next“.
  5. Choose or create a new remote location (FTP or SFTP) then click “Finish” button.

    Please note that the source file needs to be downloaded into your local drive, so choose “Yes” in the Download prompt/window. Be patient and wait for the download to complete.

  6. Select and right click on the newly created project and click on “Properties“.
  7. Select “Project Natures“.
  8. Tick “com.aptana.ide.editor.php.phpnature (PHP Nature)“.
  9. Then click “Ok” button.

After doing the changes in the source file, you can use the “Smart Sync” feature of Aptana to synchronize your local and remote source files. Another cool feature of Aptana.

Hope this helps!

Windows 7 Release Candidate 1, now available!

Microsoft has just opened its gate to public for its Windows 7 RC 1, earlier than everyone thought. The latest version of Windows 7, that is for testing purpose. Here are a few Windows 7 tidbit the you can expect on the latest version:

  • A few UI tweaks (look and feel) and additional functionality.
  • A media sharing options for Windows 7 called Remote Media Streaming.
  • Windows XP emulation. Need I say more?
  • Starter Edition for little lappie (netbooks).

Hurry and download it now! The RC version will be available at least through July 2009 with (almost) unlimited product keys. By the way the RC version will expire on June 1, 2010. Download and read the rest of the instructions from Microsoft’s official Windows 7 download and instruction page.

Enjoy!

A Little Taste of C#

Microsoft Visual C# Express Edition

Microsoft Visual C# Express

For the past couple of days, I’ve been learning C# language. Thus far, I really enjoy learning C#. Actually after an hour of reading articles/posts and sample codes on the Internet, I was able to dive in and create a simple application. No, not that “Hello world” app, but a useful app for me.

Building Windows application was not new to me. 3 or 4 years ago I’ve built an enterprise application for a medical company using Visual Basic, version 6. I have a lot of fun building that application. Well, it’s an Inventory system, not an average inventory system but a real mind boggling system that will really turn your brain upside-down. What really makes it complicated is the integration of the company’s Business Model. We try to automate everything but within the Business Model there are a lot of complicated processes that will surely twist your brain. But anyway I’m trough with it, solved the problems, and release it just in time. What I am proud of is the result application, which is a very stable and efficient enterprise application. 3+ years running without a glitch, imagine that!

Anyway, I really like C# language. Coming from Visual Basic, C, and PHP, I haven’t had the hard time learning it. I you have the same programming background as I am; surely you’ll be able to learn the language in no time, especially if you’re into OOP paradigm. If you’re a Java developer then transition will be swift.

The first thing to remember before diving right in is in C# language “Everything is an object.” If you’re into OO then you’ll know what I mean.

Don’t worry how messy your codes will be. Just built it! Refactor later! The most important thing right now is for your app to work. Hey! Nobody gets it for the first time. Unless you’re me, right! Haha enjoy and happy programming with C#.

What’s the taste? Sweeeeettt!

Reminders and things to-do:

  1. Download Visual C# Express from Microsoft website. It’s FREE!
  2. Read a lot of samples and article/post on the Internet. Here’s a couple I’ve found (Though I haven’t read them, It might come useful to you.)
    1. Introduction to C#
    2. Learning C# by example
  3. Think of a useful project to do. Plan it and build it!
  4. While building your app, spent the time to refactor your code. You’ll be saving yourself from a lot of headaches when your app turns into a monster code-base.
  5. Always think OO!
  6. Continuously improve your processes.

Ubuntu 9.04 (Jaunty Jackalope)

Ubuntu

Ubuntu 9.04 Jaunty Jackalope

Just finished downloading Ubuntu 9.04, code-named JauntyJackalope. Its latest public release made its way yesterday April 23, 2009 PST. Though I haven’t yet installed it but judging by the couple of reviews that I’ve read, this version is kinda promising. I use OpenSUSE on my development desktop and I’m not planning on dumping it anytime soon. To be honest, I’m not really a fan of Ubuntu distro. I had the chance to try it years ago, 4 or 5 years ago, I think but after a week or so, I returned to my good ol’ FreeBSD. I guess it’s the brown theme that made me hate it. And yeah! I use FreeBSD as a desktop! Sounds geeky huh? But that was years ago, I am now using OpenSUSE distro for my desktop and it makes me feel just right. But with the latest release of Ubuntu, thing might chance!

I read a couple of reviews regarding Jaunty Jackalope and the reviews was good, it is fast, slick as Windows 7 or Mac OS X, new features/notification, EXT4 file system support, boot time improvement and updated applications.

The next release will be code-named Karmic Koala or 9.10 which will be on October 2009.

Elive E17 Compiz

Elive is an Operating System built on top of Debian GNU/Linux, customized to offer users eye-candy OS experience with minimal hardware requirements.

The video below uses Enlightenment 17 on top of Elive and a special version of Compiz called Ecomorph to achieve the eye-candy effects.

Download: http://www.elivecd.org/Download/e17-compiz