Category Archives: Uncategorized

Billplz Notes

Billplz is a malaysian’s payment gateway. It’s free to register, easy to setup and affordable.

Register free here

If you are using postman to test, add the API Key as username in Authorization tab. Choose “Basic Auth” in Type dropdown. Then enter the URL and params as usual

 

Free tools for small businesses

Some free tools you can use to start your business. The providers normally provide the free tools for basic usage. Some limitation on features and users. But if you are small, it doesn’t matter much. At least you can start with some cool softwares to support your small business

CRM – hubspot

Support Ticket/ Help Desk – freshdesk

Accounting – waveapps – need to pay to use payroll and payments

Version control – GitLab

Multiple database in CodeIgniter

How to connect to more than one database in codeigniter

Database config

$db[‘default’][‘hostname’] = “localhost”;
$db[‘default’][‘username’] = “root”;
$db[‘default’][‘password’] = “”;
$db[‘default’][‘database’] = “database_name”;
$db[‘default’][‘dbdriver’] = “mysql”;

set another config for 2nd database

$db[‘otherdb’][‘hostname’] = “localhost”;
$db[‘otherdb’][‘username’] = “root”;
$db[‘otherdb’][‘password’] = “”;
$db[‘otherdb’][‘database’] = “other_database_name”;
$db[‘otherdb’][‘dbdriver’] = “mysql”;

Sample to call

//Load another database
$DB2 = $this->load->database(‘another_db’, TRUE);

//Default database query
$this->db->select(‘first_name, last_name’);
$this->db->from(‘users’);
$this->db->where(‘id’, 99);
$query = $this->db->get();

//Another database query
$DB2->select(‘image’);
$DB2->from(‘cdn_images’);
$DB2->where(‘id’, 25);
$query = $DB2->get();

 

References

codexworld.com/connect-use-multiple-database-codeigniter

 

Ionic notes

Some notes on ionic CLI command

Create new project (will create myApp directory):

> ionic start myApp blank

(besides blank, there is option to use other template like tabs, sidemenu, tutorial, super)

  • tabs : a simple 3 tab layout
  • sidemenu: a layout with a swipable menu on the side
  • blank: a bare starter with a single page
  • super: starter project with over 14 ready to use page designs
  • tutorial: a guided starter project

Get into the directory and start service

> ionic serve

Launch editor to start coding

> atom .

Other resources

  1. ionic framework doc
  2. ionic crashed course video (~30 minutes)

Looking for a used car

Getting yourself a used car has some advantages. The most severe one is you save thousands of your money. But need to be very careful in order to get a used car with good condition.

If you are looking for a used car, try out the following websites.

  1. mudah.my – huge list of cars available
  2. carlist.my – most of the list are more or less the same with mudah. especially from car dealer
  3. motortrader.com.my – there is a rating from Goo KANTEI for the condition of the car. For some cars. Can find more cars directly from owners
  4. oto.my – related to paultan.org and carbase.my

the rest not worth to mention here. Don’t have many listings

Some general tips to purchase second hand car

  1. if possible check why previous owner sell
  2. before go to see, ask questions over the phone. The most important one whether the car still available
  3. ask to see the grant
  4. ask for any other charges on top of car price – insurance, roadtax, change name, puspakom service, loan processing etc.

Some tips on checking the condition of the car

  1. sign of accident (normally with uneven paint)
  2. any leaking on engine and absorber etc
  3. the hose and belts are in acceptable condition
  4. test drive to check on engine is smooth and no irregular sounds from the car body or engine
  5. tyre tread still ok, manufactured not more than 3 years