Sunday, September 29, 2013

Drupal - Move from live to local environment

Today i experienced in moving drupal from live to local environment.

#Problem

  1. Site redirected to live site when i open 'user/login'
#Issue
Problem may come from the site SSL setting, default Drupal settings, or the HTACCESS configuration.

#Solution


1. copy whole site folder to local server. (example: /public_html)
2. copy the database to local server.

3. investigate & update the database

4. update setting files
5. update .htaccess

thats all.

Friday, September 20, 2013

Installation phalconphp in AWS completed



I just install phalconphp in AWS Freetier instance.
I faced 2 problems only prior installation;

  1. E: Unable to fetch some archives, maybe run apt-get update or try with --fix-missing?
  2. make: command not found

sudo apt-get remove make
sudo apt-get install make

AWS still charge you even your take the freetier one but its not to much.
People always want to point the server ip to his or her domain.
So you need to know how to configure CNAME or you can use AWS Route53 paid service.
Thats all.

Reference:

Tuesday, September 17, 2013

Android debugging over wifi

1. We need to start over all USB debugging from terminal

#to kill all previous connection
adb kill-server


2. Revoke USB debugging authorization Android > Settings > Developer > Revoke USB....

3. Replug your phone to computer
4. Set adb tcpip port from terminal
#to set adb tcpip port
adb tcpip 5555


5. Make sure your phone set tcpip port 5555

#to connect your phone as super user from your computer
adb shell


#to set the port
setprop service.adb.tcp.port 5555

#exit from the android shell
exit


6. connect to phone
#to set the port
adb connect [your-phone-ip]


Reference: http://stackoverflow.com/questions/2604727/how-can-i-connect-to-android-with-adb-over-tcp

Laravel 4 get started in MacOSX terminal


  • Create  your project folder
  • Install composer

$ curl -sS https://getcomposer.org/installer | php


  • Install laravel using composer

php composer.phar create-project laravel/laravel your-project-name --prefer-dist

Referance:

Saturday, September 14, 2013

Susah tak HTML5?

Apabila ada seseorang ditanya tentang HTML5 depan aku, aku akan diam kan diri dengar apa yang orang itu jawab.

Biasanya mereka akan pandang atas. Memikirkan jawapan untuk soalan itu. Kemudian dijawabnya panjang lebar.

(^_^)'

2 perkara asas yang kita perlu tahu dan mungkin yang hanya perlu diambil berat;

  1. HTML5 adalah HTML yang diintegrasikan elemen-elemennya dengan fungsi yang ada pada sesuai peranti itu.
  2. HTML5 datang untuk meringkaskan HTML terdahulu.
picture from Complete Web 2.0

Itu sahaja. Sesuatu yang kita tahu kita akan bimbang untuk menggunakannya. Selain itu, kita hilang arah bagaimana untuk menguasainya sekiranya kita fahaminya dengan keadaan kompleks.

Ringkaskan HTML5?
Selamat mencuba!

Wednesday, September 4, 2013

Android foreground &background event firing

Hey guys, here i wanna share the way to implement foreground and background event firing.

In appcelerator titanium, we need to wait the first window opened before we register the events. Thats all.

Note:

if you want to implement background service trigger after application minimized as happen in iOS, you should use 'stop' event. This is because 'pause' event also fired when ever your window blured.

In android, window blur event triggered when ever a dialog opened or a modal window opened.

So, simple to say here is android puase event equal to window blur event.

Check out the code in my personal repo here.