Category Archives: Web

Posting to FB pages from web application

This is the code: $appId = ‘YOUR APP ID’; $secret = ‘YOUR SECRET’; $returnurl = ‘’; $permissions = ‘manage_pages, publish_stream, offline_access’; $fb = new Facebook(array(‘appId’=>$appId, ‘secret’=>$secret)); $fbuser = $fb->getUser(); if($fbuser){ $page_id = “YOUR PAGE ID”; $page_access_token = “GET PAGE TOKEN ID”; $result = $fb->api(“/me/accounts”); // loop trough all your pages and find the right one […]

Shortening URL with and PHP

// This is the URL you want to shorten $longUrl = ‘’; // Get API key from : $apiKey = ‘MyAPIKey’; $postData = array(‘longUrl’ => $longUrl, ‘key’ => $apiKey); $jsonData = json_encode($postData); $curlObj = curl_init(); curl_setopt($curlObj, CURLOPT_URL, ‘’); curl_setopt($curlObj, CURLOPT_RETURNTRANSFER, 1); curl_setopt($curlObj, CURLOPT_SSL_VERIFYPEER, 0); curl_setopt($curlObj, CURLOPT_HEADER, 0); curl_setopt($curlObj, CURLOPT_HTTPHEADER, array(‘Content-type:application/json’)); curl_setopt($curlObj, CURLOPT_POST, 1); curl_setopt($curlObj, […]

7 online tools to start with for a new website

Google Structured Data Testing Tools Facebook Debugger Facebook Comments Box Facebook Like Box Google+ Web Share Google+ Badge Facebook Badge

Adding structured data to your content

My latest project is another never ending experiment baby. This time I am using Events schema to have my website listed in search engine together with the auction events that are going to happen. According to Google, this will help visitors to visit the best page that they are looking for. I have to […]

How to use Google+ picture as your web favicon?

Do this: <link rel=”shortcut icon” type=”image/jpeg” href=”[your google+ id]?sz=16″/> example: <link rel=”shortcut icon” type=”image/jpeg” href=”″/> Put this line between <head> and </head> of your web page. For wordpress, find it in header.php file (in theme editor).

Gambar profile dalam keputusan carian Google

Kawan saya Fendi ada bertanya tentang cara bagaimana nak keluarkan gambar profile beliau dalam laman search result oleh Google. Ini di panggil Google Authorship. Senang saja. Dalam beberapa steps dah boleh buat. 1. Buka akaun Google+. 2. Pastikan link profile anda, contoh:[nombor profile]?rel=author jadi sekiranya nombor profile anda adalah 009988, maka link profile anda […]

My first microdata looks good

So i just tried this microdata things for my project. I made the homestay view page to return product info, offer, geo-location, address and ratings. Now the microdata test tool display exactly the way I want it to be, where the offer name and price displayed on search result page, try it here. I […]