Wednesday, 23 November 2016

What is the maximum size of JSON data that web browsers could handle?

As you can see from my results, the browsers were all surprisingly close to one another. The most interesting part for me was that Internet Explorer failed to load the object after the 250,000 record test. I couldn’t find anything pointing to a size limitation here. If anyone knows as to why IE failed to load the 500,000 record object, let me know.
From this test, I am considering the sweet spot to be around 10,000 records at (1.55MB). The maximum number of usable records I would push to a browser would be around 25,000 records (3.87MB). Keep in mind there are numerous factors to keep in mind when determining how many records you should return to your JavaScript application. The purpose of this test was to help identify a general maximum number for conversations around large record sets with JSON.


Tuesday, 22 November 2016

Why JavaScript counts month from zero (0)?

One possible explanation:

They might've considered months to be an enumeration (first index being 0) and days not since they don't have a name associated with them.
Or rather, they thought the number of the day was the actual representation of the day (the same way months are represented as numbers in a date like 12/31), as if you could make a enumeration with numbers as the variables, but actually 0-based.
So actually, for the months, perhaps they thought the proper enumeration representation would be to use the month's name, instead of numbers, and they would've done the same if days had a name representation. Imagine if we'd say January Five, January Sixth, instead of January 5, January 6, etc., then perhaps they'd have made a 0-based enumeration for days too...
Perhaps subconsciously they thought about an enumeration for months as {January, February, ...} and for days as {One, Two, Three, ...}, except for days you access the day as a number rather than the name, like 1 for One, etc., so impossible to start at 0...

Monday, 31 October 2016

How To: Tethering a Mac to an Android phone

Tethering is connecting one device to another. In the context of mobile phones and tablet computers, tethering allows sharing the Internet connection of the phone or tablet with other devices such as laptops. (
HoRNDIS (pronounce: “horrendous”) is a driver for Mac OS X that allows you to use your Android phone's native USB tethering mode to get Internet access. It is known to work with Mac OS X versions 10.6.8 (Snow Leopard) through 10.12 (Yosemite – see notes below), and has been tested on a wide variety of phones. Although you should be careful with all drivers that you install on your computer, HoRNDIS has been tested at least well enough for the author (and many others) to run full time on their own personal computers.

HoRNDIS is implemented as a kext, rather than as a user-space program that opens a TAP or TUN device; this means that it does not conflict with other TAP/TUN kexts that you might have installed (like OpenVPN, Tunnelblick, or Cisco VPN). The driver implements Microsoft's proprietary RNDIS protocol, which is the only protocol supported natively by Android devices; although Linux and Windows users have enjoyed native RNDIS drivers for years, Mac OS X supports only CDC Ethernet devices out of the box.1)

The chief advantage of HoRNDIS over other tethering solutions is that it uses the a first-class supported feature in the phone's firmware. Other solutions either take over the phone's Wi-Fi stack without the Android operating system's knowledge, or create an emulation IP stack in userspace on the phone; in many cases, the built-in USB tethering support can be more stable, more reliable, and faster.2)

Downloading and installing HoRNDIS

HoRNDIS is available in source form from its project page on GitHub, and in binary form on this site. For quick start instructions:

Download the latest binary package, and double-click on it in your Downloads folder. Follow the instructions in the installer.
Assuming that the installation proceeds without errors, after it completes, connect your phone to your Mac by USB.
Enter the settings menu on your phone.
In the connections section, below Wi-Fi and Bluetooth, select “More...”.
Select “Tethering & portable hotspot”.
Check the “USB tethering” box. It should flash once, and then become solidly checked.
On some versions of OS X, a dialog box may pop up, prompting you to configure the device; follow its instructions. To verify that the device is connected, start the System Preferences program, and select “Network”; you should see your phone appear in the box at left. With any luck, you should be able to turn off Wi-Fi on your Mac, and browse the Internet through your phone's network connection.

Available versions

The latest version available is release 8: HoRNDIS-rel8.pkg (78985 bytes) (md5sum 8991552bd384a06b7ec775f7198f7bba; GPG signature). Adds support for OS X 10.11 (El Capitan) and 10.12 (Sierra). Thanks also to David Ryskalczyk for his help in wrestling Xcode.
Older versions:
Release 7: HoRNDIS-rel7.pkg (116491 bytes) (md5sum 45a1a7457966b1dc79897af2864f68e4; GPG signature). Adds support for OS X 10.10 (Yosemite). Fixes issue where unsigned kext would not be installed (restoring support for OS X 10.6 - 10.8). Thanks also to David Ryskalczyk for his help in tracking down the issues with 10.10.
Release 6: HoRNDIS-rel6.pkg (116473 bytes) (md5sum fe3e5ae4c0a509b06cf11ef65b1715da; GPG signature). Adds support for multicast mode, enabling mDNS (thanks to Dan Yocom at Intel). Adds code signing support in Installer and for kext.
Release 5: HoRNDIS-rel5.pkg (60906 bytes) (md5sum 059164db5a76e5c0b57b9ef9acb65da5; GPG signature). Adds support for Mac OS X's Internet Connection Sharing, enabling BeagleBoard users to connect their boards to the Internet through their Macs.
Release 4: HoRNDIS-rel4.pkg (60519 bytes) (md5sum 8cf81024d8514d2a8654420fc7491b84; GPG signature). Actually fixes issue #5 and #9, adding support for Samsung Galaxy S II and HTC Desire S (thanks to Griskha). Improves compatibility with older versions of OS X (early 10.6).
Release 3: HoRNDIS-rel3.pkg (60488 bytes) (md5sum a46960e3cdb2a046e08af00c766b6ff9; GPG signature). Fixes issue #3 (reenabling installation on 32-bit machines). Adds potential fix for issue #5.
Release 2: HoRNDIS-rel2.pkg (60843 bytes) (md5sum 8b2c371e78ccfe3b07750fbe07f55bb5; GPG signature). Disables installation on 32-bit machines, and includes new device support.
Release 1: HoRNDIS-rel1.pkg (38681 bytes) (md5sum 4169c222448e2a2caaa067caf84189d3; GPG signature). Fixes issue #2.
Release 0: HoRNDIS-rel0.pkg (36807 bytes) (md5sum be4e879198d3b6e52af993b008198e8e; GPG signature). Initial release.

A special note about 32-bit machines

In previous versions, HoRNDIS required a 64-bit kernel. If you get an error message about 64-bit support on installing HoRNDIS, please try again with the version 3 package (or newer).

Notes about specific Mac OS X versions

OS X 10.9 (Mavericks) and 10.10 (Yosemite) are supported by HoRNDIS, but there are some gotchas. If you upgraded from an earlier version of OS X, you may find that phones appear to be replicating with abandon in your network control panel. If this happens to you, one somewhat heavy-handed workaround is to clean your network configuration files – take a backup of /Library/Preferences/SystemConfiguration/NetworkInterfaces.plist and /Library/Preferences/SystemConfiguration/preferences.plist, and then either move them out of the way or delete them. (Note that this will remove any custom network configuration that you have performed!) I am still not sure what causes this problem, and so I do not yet have a workaround with finer granularity.

Versions of Mac OS X 10.11 and newer have a rewritten USB stack that is substantially less compatible than that in 10.10 and below. Unfortunately, Apple have not published any documentation for the new-style USB interfaces exposed in 10.11, so HoRNDIS can only use the USB APIs available in 10.10 and below, which have been broken in newer versions of OS X. As such, newer versions of OS X may have difficulty connecting to certain devices.


If, for some reason, you need to uninstall HoRNDIS, you can simply drag the extension to the trash. In the Finder, go to the “Go” menu, and select “Go to folder...”; in that, type ”/System/Library/Extensions”. Find “HoRNDIS.kext”, and drag it to the trash. When prompted, type your password. Do the same for the “HoRNDIS.kext” that lives in ”/Library/Extensions”, as well. Then, restart your Mac to be sure it is unloaded.

Getting and building the source

(Fork me on GitHub!) The source is available on GitHub; it is licensed under the GNU General Purpose License, version 3. To build the source, you'll need Xcode 4.0+ installed; to build a version that will work under Snow Leopard, you will also need the Snow Leopard SDK installed. Unfortunately, the Snow Leopard SDK is hard to come by nowadays; you'll need to find it somewhere on the web, and manually install it into your Xcode SDKs folder. (For most applications, it's OK to build against a newer SDK; for a kernel module, the magic vtable space-saving tricks require you to compile against the lowest common denominator.)

Simply running xcodebuild in the checkout directory should be sufficient to build the kext. If you wish to package it up, you can run make to assemble the package in the build/ directory (though please don't publish versions you built as if they were official!).


On the shoulders of giants, I stand. My vague thanks to Apple for having at least some IOKit sample code available (even though the last time it successfully built was 10.2.x); it was a decent start reading to understand how I might want to structure this. Substantial thanks to David Brownell, who wrote the rndis_host driver for Linux; some portions of HoRNDIS were ported over from that work. David Brownell also wrote the f_rndis driver that allows Android/Linux devices to behave like RNDIS devices; reading that source helped to understand why HoRNDIS wasn't working in the early stages. (Sadly, David Brownell passed away in April of 2011. Thanks for all of your hard work, David; may you rest in peace.)

Thanks also to those who helped test HoRNDIS before I released it, as well as all of the other folks from the days of the unrEVOked project, without whom I would likely not be involved in Android development at all...

Support and contact

And, after a tenure of three years, I am looking for a new maintainer for HoRNDIS. I no longer have the time to keep HoRNDIS up to date the way it deserves. If you believe that you have the skills to take on maintainership of this software, please let me know, or post in this GitHub issue.

Being free software, HoRNDIS comes with no warranty (not even a guarantee that it won't break your phone or computer! But I'm pretty sure it won't.), express or implied. (For more on that, read the license.) However, I hope that it works for you; if it doesn't, and you're able to assist in debugging, I'd like to hear from you.

So, for feedback, feel free to get in touch with me; especially if it works for you, or makes your life easier, I'd like to hear about it!


Wednesday, 5 October 2016

Solution To: Maya 2016 Grid Not Showing Up

PROBLEM: Maya Grid Not Showing Up

a) Check that you have enabled grid in the Display Menu

b) Check that you have enabled grid in the Show Menu

c) Reset Maya Preferences. (Refer here)

Solution To: Maya 2016 Outliner Window Not Showing Up

PROBLEM: Maya Outliner Window Is Missing.

SOLUTION: Refer Maya Troubleshooting Guide.



In some instances, Maya will not start or strange issues inside the UI will occur like missing menus or slow performance in the UI when moving objects in vertex mode, due to corrupted preferences.


Refresh the preferences by using the following steps: 

  1. In the Finder, click the Go menu and then click "Go to folder..."
  2. Type /Users/USERNAME/Library/Preferences/Autodesk/maya/VERSION/
  3. Click "Go"
  4. Find the prefs folder and rename it to prefsOld
  5. Restart Maya and if prompted to select the option to create default preferences.
  1. Rename the prefs folder found in the following location to something like prefsOld:
    • Windows 64-bit: C:\Users\USERNAME\My Documents\maya\VERSION\
    • Windows 32-bit: C:\Users\USERNAME\My Documents\maya\VERSION\
  2. Restart Maya.
  3. If prompted to, choose the option to Create Default Preferences.

  1. Rename the prefs folder found in the following location to something like prefsOld
    • ~<username>/maya/VERSION/
  2. Restart Maya.
  3. If prompted to, choose the option to Create Default Preferences.
Note: On all systems it is possible to rename the folder that is named the version of maya for instance "Documents/maya/2016" can be renamed "Documents/maya/2016Old" to reset more files.

Sunday, 7 August 2016

Solution To: "Warning: date() []: It is not safe to rely on the system's timezone settings" (PHP)

Error (PHP):

date() []: 
It is not safe to rely on the system's timezone settings.
You are required to use the date.timezone setting or 
the date_default_timezone_set() function. 
In case you used any of those methods and 
you are still getting this warning, 
you most likely misspelled the timezone identifier. 


1. Edit PHP.ini, uncomment the date time
date.timezone = Asia/Kuala_Lumpur

2. Edit PHP script, add the date time statement
if( ! ini_get('date.timezone') )

Further References:

Friday, 24 June 2016

How To: Use SketchUp Without Install

How To: Use SketchUp Without Install

1) Browse The SketchUp Site

Click Run.

2) Sign Up

Check your mailbox for a link to set password for your account.

3) Install Turbo VM Extension

4) Install SketchUp Online

Type “sketchup” to search for the app and click “Add” to add it to the system.

5) Run SketchUp Online

SkecthUp version as at 25th June 2016

Tuesday, 21 June 2016

How To: Create Jigsaw Using Vector Program (InkScape)

Question: How to create jigsaw pieces in vector format?
Question: How to create jigsaw pieces in svg format?
Question: How to create jigsaw pieces in ai format?


The first thing we need to do is to create the basis for our puzzle - a path wich will cut our image to pieces. For that we need to download and install special extension for Inkscape by Neon22, that creates jigsaw shaped pieces (How to install extension in Inkscape). After installation, we can find it here: Extension > Render > Lasercut Jigsaw.

My image has 1000x700px resolution. So I launch the extension and set my width and height parameters

Note: 1000 height and width is the maximum

The next thing we need to decide, how many puzzle pieces we want to create. I chose 5 pieces across and 3 pieces down. Then Press Apply.

What we now have - is a group of paths. In order to proceed, we need that each puzzle piece was closed and has its own path. So we ungroup the puzzle template (Shift+Ctrl+G several times), select all curving lines and go to Path > Combine or press Ctrl+K.

Selection Tip: Select all (Shift+A) and then, holding down the Shift Key, deselect the border shape

Now they all became one object. Then we select it and the remaining border shape and go to Path > Division or press Ctrl+/

Note: Make sure that the inner object is on top (go to Object > Raise to Top or press Home key). Otherwise, it won’t work

Save your template as an svg and move to Gimp. Open there your initial image, go to Tools > Paths and import our svg by right clicking on the Tab. Further, we need to download special plugin for Gimp by devolonter (How to install plugins in GIMP).


Sunday, 19 June 2016

Difference between CV and Resume

The CV presents a full history of your academic credentials, so the length of the document is variable. In contrast, a resume presents a concise picture of your skills and qualifications for a specific position, so length tends to be shorter and dictated by years of experience (generally 1-2 pages).
CVs are used by individuals seeking fellowships, grants, postdoctoral positions, and teaching/research positions in postsecondary institutions or high-level research positions in industry. Graduate school applications typically request a CV, but in general are looking for a resume that includes any publications and descriptions of research projects.
In many European countries, CV is used to describe all job application documents, including a resume. In the United States and Canada, CV and resume are sometimes used interchangeably. If you are not sure which kind of document to submit, it is best to ask for clarification.


Saturday, 11 June 2016

Download: Free Disc Burner

CDBurnerXP is a free application to burn CDs and DVDs, including Blu-Ray and HD-DVDs. It also includes the feature to burn and create ISOs, as well as a multilanguage interface. Everyone, even companies, can use it for free. It does not include adware or similar malicious components.


Q&A: Can I install both Java 32 bit and 64 bit on the same pc?

Can I install both Java 32 bit and 64 bit on the same pc?



Solution To: ProjectLibre requires Java version 6 or later.

ProjectLibre requires Java version 6 or later. Please install Java:

Install java 32-bit edition.

Thursday, 9 June 2016

How To: Use Microsoft Word Online

Using Free Microsoft Word Online
If you haven’t got a Microsoft Account, go here,

1) Select Word Application

Click the button showing Word icon.

2) Familiarize with Word Online Page.

3) Create new document

Click the button New blank document.

4) Start using Word Online Editor window

5) Install Chrome Extension (if you are using Chrome Web Browser)

6) Start using it!


How To: Install Chrome Extension for Microsoft Office Online Application

Install Office Online Extension for Chrome

1) Install Button

If you are a new user of Office Online applications, you may get this message on your first time using it. Click the button “Get the extension”.

2) Chrome Extension Page

Alternatively, you can click this link to go the Chrome Extension Page.
Click the button “ADD TO CHROME” .

3) Give permission to Chrome to download and install extension

Once installation has been successful, you may get some application message at bottom right of window.

Register For Free Office Application

101 Register For Free Office Application
You need to have a microsoft email service such as or
If you already have it, skip step no.1 to no.3. Otherwise, start with step no. 1.

1) Browse the website

Browse or  (Both URLs will ultimately reach ).
Click the button “Sign up for free”.

2) Create a Microsoft account.

Click the button “Create a Microsoft account”.

3) Get a new email address

Click the button “Get a new email address”.
Enter your preferred email name and password. You may be required to reenter different email names if the one you entered has been used by other people.

4) Login

If you already have an email with Microsoft such as or , click the button “Sign in”.

5) Dashboard Page

Once you have successfully logged into this site, you will see the starting page a.k.a Dashboard Page.

6) Start Button

There is a Start Button at the top left of the page. Clicking it will trigger the popup menu showing all online Microsoft Office Applications.
From here, you can start using the following applications:
  • Mail
  • Calendar
  • People
  • OneDrive
  • Tasks
  • Word
  • Excel
  • PowerPoint
  • OneNote
  • Sway
  • Office
  • Bing
  • MSN