ZXingObjc encode QR code

To generate QR code in iOS device, I’m using this library.

From the their GitHub repo, already got the instruction. Here I want to point out 2 things:

Read More

Effectively debug UIView in Objective-C

Usually I’m using NSLog to debug all sort of objects.
When I encounter UINavigationBar background color issue,
I loop through it’s subviews one by one. e.g.

Read More

Dealing iOS 7 UIStatusBar

I have a hard time on dealing with iOS 7 status bar.

In this example, I will set the status bar for each UIViewController

So now go to Info.plist file, and set View controller-based status bar appearance to YES

Read More

How to add Google Map to your web page

Introduction

Here is to shows you how can you add google map to your web page by JavaScript (not using iframe). Besides, you will also learn about searching, and marker dragging.

Read More

Draw a shape using UIBezierPath

Shape wanted

To draw the shape above by UIBezierPath

Read More

UIView fill with color and leave a empty square in center

UIView

Create a UIView that fill with color, and leave an empty in center.

Read More

Setup Wordpress on shared hosting

Description

Now we want to setup WordPress manually on shared hosting.

Read More

Match & Replace NSString using Regex

In this example shows, to display current date in a label in a specific format (e.g. 31/12/14 12:59PM)

You can see the date format

Read More

jQuery bind event dynamically

Bind event dynamically means to bind the event to new DOM element added from jQuery/JavaScript.

e.g.

1
2
3
4
<div id="btn-wrapper">
<button type="button" id="btn-1">Button 1</button>
<button type="button" id="btn-2">Button 2</button>
</div>

Read More

MySQL count with subquery

Example

Below shows a forum web app. A post can only post by 1 user, its reply can reply by many users

Read More