## Fix Godaddy sub-domain forwarding for wordpress

I created a wordpress website with its own domain name on my Godaddy account. However, after that domain name expired, I still want to archive the website content as a sub-domain of my account. Then, I created a sub-domain under my main domain name (see acdt2017.defta.org and acdt2016.defta.org as examples). But after I created those sub-domain names and select the correct site folders, the forwarding don’t work. They still linked to the old domain name.

To fix this, I did followed my own post at http://kerdsri.com/2016/05/04/changing-url-for-wordpress/

By adding these two line of code in config.php

define(‘WP_HOME’,’http://your_sub-domain’);
define(‘WP_SITEURL’,’http://your_sub-domain’)’);

Now everything is working correctly ^_^

## Using Temperature Data-logger RC-5 on Mac OS X Seirra

I bought this Elitech USB Temperature Data logger URC-5, hoping to find the right place for my home-brew frementation. The product kit doesn’t come with Mac software so I have to download it from http://www.elitechus.com/software.html.

However, the USB driver provided crashed my Mac OS X 10.12 (Seirra).  I tried digging around on the Internet and found out that I need an update version of CH340 CH341 serial adapters on macOS 10.12 Sierra. Thanks to https://tzapu.com/ch340-ch341-serial-adapters-macos-sierra/ ^_^

Therefore, after you install the management software, you’ll need to install the updated CH340 driver instead. After a few tries, it has been working flawlessly.

## Regarding Low-Carb diet

A few weeks ago, I came across with a Ketogenic diet group and it looks really promising. This method is similar to Atkin’s Diet by cutting down the carb consumption (the difference between Atkin and Ketones diet can be found here).

However, the Keto diet aims to put the body in the the ketosis state where the fats are burnt as a source of energy instead of carbohydrates. In addition, Keto people must consume a high amount of fat (good fat) so the liver can break down the fat cells into fatty acids and ketones. This method is believed to control the blood sugar and minimize the insulin in our body. Keto diet is quite specific on their food consumption (as shown in figure below).

I tried this Keto diet for a few days. I felt like loosing energy and moody (from the lack of Carb) but it’s really result in weight loss.

Nonetheless, I am curious about the alcohol effect on this Keto diet since I’m a home-brew and beer lover. From my gathered information, beer is not good for low Carb diet because it contains lost of carbohydrates. Basically, you want to avoid anything red, amber or dark.

All in all, Keto diet is not for everyone!!! especially who still enjoys the life of taste like me. So, I think I’ll stick with normal low-carb diet and normal exercise (like Atkin’s diet) in order to sustain the state of beer drinking.  Basically, I’ll exercise to compensate my Carb intake from beer.

Cheers,

## How to change iPhone screen to gray scale display #iOS10

Thai people are on the period of the greatest loss and despair.
Since now we are in sorrow and tears are in our faces, we can be in mourning in different ways.

1. First go to setting > Accessibility

2. Under the Vision > Display Accommodations

3. Select Color Filters > Grayscale

4. Done! now you can see the world in Grayscale.

## Changing URL for WordPress

Recently, I have to change a URL for one of my WordPress websites. After a new domain name was pointed to the location of WP directory on my server, my website didn’t correctly show due to some elements still linked to the old URL. To fix this, I have to tell WordPress a new URL by putting these two lines in wp-config.php

define('WP_HOME','http://newURL'); define('WP_SITEURL','http://newURL');

## ATOM as my favourite editor for Thai LaTeX document

From Github, Atom is an open source text editor that I’m interested for quite sometimes. In fact, I’ve been using SublimeText for a very long time because I love its speed and functions. The big problem of SublimeText for me is it can’t render Thai character correctly. This is a big deal for me since I once in a while need to write in Thai.

When I first tried out Atom, I really impressed that it can properly show Thai character. After a while, I come to love its community of developers behind it. I have to work with tons of LaTeX documents and I think now Atom is the answer for me.

Here is how I set up the packages to work with LaTex (especially for Thai). Big Thanks to MATTEO MEROLA blog for this guidance of setting LaTex for Atom.

2. Go to Atom > Preferences and install these packages.
• language-latex
• linter-chktex
• spell-check
• latexer
• latex-plus
• dictionary
• zen
• wordcount
• git-plus
• project-manager
• minimap

3. You’ll need to put the TeX path in the latex-plus setting.
4. Done! now you can write and compile your LaTeX document.
5. In order to use Thai, you’ll need to use XeLaTeX.
6. Set up a new project and create a simple LaTeX document as follow:
7.  \documentclass[a4paper]{book} \usepackage{xltxtra} \usepackage{polyglossia} \usepackage[top=25mm, bottom=20mm, left=25mm, right=25mm]{geometry} \usepackage[titletoc,toc,title]{appendix} \setmainfont{TH SarabunPSK} \defaultfontfeatures{Scale=1.23} \renewcommand{\baselinestretch}{1.2} \setdefaultlanguage{thai} \newfontfamily{\thaifont}[Script=thai]{TH SarabunPSK} \begin{document} ทดสอบภาษาไทย \end{document} 

8. Now go to Atom menu > Packages > LaTex-Plus > Edit
9. In the program, change to “xelatex”
10. Viola! now you can enjoy, writing LaTeX document in Thai ^_^

## DIY bedside table

I got the inspiration from SANDHOG of Ikea bedside table for this DIY table.

What I want?

A bed side table for my iPhone and Apple Watch with the charging cable hide inside this table.

What you need:

1. Paper Bucket: I got this bucket for $3 USD 2. Paper Clip 3. Extension Power Board 4. Plastic Mat So, the total budget is around$10 USD.

1. Cut two holes with scissors on the near top and bottom of paper bucket for the power cable.

2. Use the paper clip to hang the extension power board inside the bucket.

3. Done! I put a round plastic mat on the top of the table to prevent a scratch for my devices. Enjoy ^_^

## My Korean Series List

Updated 17-04-2016: from now on, I’ll update my list at http://www.imdb.com/rg/s/1/list/ls038586423/

I’d like to keep a list of K-series that I’ve watched. This list is ranked by my favourite of romantic comedy.

## using Thai with LaTeX on Mac OS X

Here the thing, while I was writhing my thesis using LaTeX with the template that Dr. Gordon created, I have to write a long research report for my work.
So I have a though of using LaTeX to create that report since I already fond of the way LaTeX writing can help me organize and create beautiful PDF report.

However, it’s not easy as I thought since I have to write that report in Thai and Thai language is designed to be difficult to use in the digital world. I have to dig around for a couple days in order to use Thai with LaTeX especially on OS X.
Here is how I did it:

1. First we’ll need to install TeX Live, for Mac we need to install MacTex
2. Once you install the MacTex then you’re ready to use international language with LaTeX using XeTeX typesetting engine.
3. Then you’ll need a tool with XeTeX engine to write LaTeX. I recommend Texmaker because it’s free and super powerful.

4. After installing you will have to set up the typesetting by go to Texmaker > Preferences > Quick Build > XeLaTex + View PDF
5. Finally test your environment by creating new document with this code


You should see Thai language is working correctly, if not check if you system has Thai Sarabun font installed? You can download this official Thai font from SIPA

The main point is you’ll need to tell LaTeX to use Thai font
\usepackage{font spec} % To enable non-standard font selections \setmainfont{TH SarabunPSK} % A font with Thai glyphs \XeTeXlinebreaklocale ’th_TH’ % Thai-style word-breakings and line-wrappings 
Enjoy Thai LaTeXing ^_^