CHM Can't Be Opened With Message 'Navigation to the webpage was cancelled'

Recently, I downloaded an ebook in form of .CHM file (Compiled HTML). Then, I tried to open it but it failed instead showing 'Navigation to the webpage was cancelled' message. I tried to download it over and over until I realized that I should find the solution just by googling it... :D

image5.jpg
source: http://goo.gl/Ua6T0

One of workaround that I used is by right-clicking the file with my mouse and then open the properties, afterward click the unblock. This problem is quite old and due the fact of exploit(s) that maybe come from this typical file.

Setting up MySQL from WAMPServer to be used alongside with Ruby on Rails in Windows Vista

Dear Readers,

Recently, I got into the project that will be using Ruby on Rails as its platform. Okay, let's get through to the setting up environment process.

My system list:
  • Windows Vista Ultimate SP 1
  • WAMPServer consists of Apache, MySql, PHP stack. (We will only make use of its MySQL)
1. First get the Ruby if you haven't yet here: http://www.ruby-lang.org/en/downloads/
I'm using the latest stable one (Ruby 1.9.2-p136)
2. Find your download and click the installer. For your convenience, don't forget to add the Ruby to the PATH in system's environment variables by clicking 'add to path' section. Otherwise, you have to add the Ruby.exe to the PATH manually.
3. After the ruby installation completed, run the command prompt and check if you can use command ruby by typing it.
4. Ruby 1.9.2 doesn't seem support command gem update --system. It always draws error message. I dunno any workaround on this problem. But, if you use older version such 1.8.6, then it should be fine. 
5. Okay, you have it worked then you should install the required gem (library) for rails by typing gem install rails. If you success, then at this step you have completed setting up the rails environment.

Now, we move to setting up MySQL database used in WAMPServer. Maybe some of you questioning why use WAMPServer's MySQL stack? The motivation behind this is because I'm heavily developing PHP using WAMPServer and it seems redundant to install a new MySQL database so why not to make use the installed MySQL database on WAMPServer. Save space. :)

6. Okay, start the WampServer. Make sure to turn off the Apache server's service and let MySQL service run and make sure it is running. Find the WAMPServer icon on the taskbar > MySQL > My.ini. Open and edit it. Add bind-address = 127.0.0.1 under the socket section. This will tell MySQL server to bind with local apps.
7. Open the MySQL console and login to it. By default, there is no password for root user so you can leave it empty when being prompted for password. Create the database for your rails application by using this sql statement: create database `<database name>`;. Replace <database name> with a name for your application's database. For example: rails_test
8. Install the Ruby gems for MySQL by typing gem install mysql

Now, we will create a new Rails project. With command prompt, browse to your pre-defined rails project folder. For example, My project folder is in my document folder and under programming sub folder (my documents > programming > myrailsproject).
9. Create a new project by typing command: rails new <project_name> -d mysql. -d mysql option is required to specify the DBMS that we used for the project. By default, it will use sqlite.
10. Inspect the project folder (the project's name is the same with the <project_name> you specified when create a project in the step before). Then inspect the config folder. Open and edit database.yml. Please make sure the database name is the same with the database name on MySQL. (You can make database entry for the test and production too in MySQL before and bind each in database.yml configuration)
At this step you have configured the WAMPServer's MySQL to be used with Ruby on Rails Project. :) 

Happy Sharing Codes Using Gist

It is sooooo late until I discovered http://gist.github.com. This is a Software as a Service (SaaS) provided by Github to be a tool for sharing code snippets or plain texts. As you may be thought that there are several similar service such pastebin. But, Gist offered Github power of versioning system which you can manage your code snippets through change by change without worrying that your code being rewritten completely as Github always handles the backup. It is also mean that you can create your local codes repository on your desktop computer by cloning the git.

Let's take a look on the Gist's UI.

Gist_ui

  1. Pick a name for your source code. Please take a note that if you add the file extension such as .java / .txt. Gist will automatically highlight your snippet text to recognizable keywords of the programming language that you specified.
  2. Otherwise, you can do it manually as you pick your language here.
  3. Make your description about the snippet code. It can be anything you want.
  4. Write your snippet text here. Please take a note that indentation will not be formatted automatically to your snippet. You should specify yourself by adding appropriate space(s).
  5. This enables you to create batch snippets.
  6. You can choose to post the snippet as private Gist
  7. Otherwise, you can make it public

As you post your snippets, it will be given an ID to be noted so you can manage it any time. For extensive snippets management, you should claim the snippet you made using your Github's account.

If you use Posterous to blog as myself you should be happy because Posterous has been friend of Gist for quiet time. You may take a look what Gist would look like on my "updated" previous article: http://bruteforce.posterous.com/hello-world-3016

Scraping Links With PHP

In this tutorial you will learn how to build a PHP script that scrapes links from any web page.

What You’ll Learn

  1. How to use cURL to get the content from a website (URL).
  2. Call PHP DOM functions to parse the HTML so you can extract links.
  3. Use XPath to grab links from specific parts of a page.
  4. Store the scraped links in a MySQL database.
  5. Put it all together into a link scraper.
  6. What else you could use a scraper for.
  7. Legal issues associated with scraping content.

What You Will Need

  • Basic knowledge of PHP and MySQL.
  • A web server running PHP 5.
  • The cURL extension for PHP.
  • MySQL – if you want to store the links.
Backhoe Digging

Read the rest of this entry »

Information Technology Sector at CNNMoney's Best Jobs in America

Recently, CNNMoney.com released a top 100 list for the Best Jobs in America. There are 26 jobs in total competitively to Health Care sector which also has 26 jobs too. It shows us that the Information Technology sector takes important role to the US economics since these best jobs provide a better way to live as American facing hardship to economic situation.

 

Okay, here we are the best jobs in America for Information Technology:

 

 

Information Technology Software Architect 1
  Information Technology Database Administrator 7
  Information Technology Information Systems Security Engineer 17
  Information Technology Software Engineering / Development Director 18
  Information Technology Information Technology Manager 20
  Information Technology Telecommunications Network Engineer 21
  Information Technology Network Operations Project Manager 24
  Information Technology Information Technology Business Analyst 26
  Information Technology Information Technology Consultant 28
  Information Technology Test Software Development Engineer 30
  Information Technology Information Technology Network Engineer 31
  Information Technology Information Technology Program Manager 33
  Information Technology Computer and Information Scientist 35
  Information Technology Programmer Analyst 37
  Information Technology Applications Engineer 38
  Information Technology Systems Engineer 49
  Information Technology Information Technology Specialist 60
  Information Technology Systems Administrator 66
  Information Technology Web Developer 67
  Information Technology Technical Services Manager 70
  Information Technology Information Technology Systems Manager 77
  Information Technology Information Technology Training Specialist 79
  Information Technology Technical Writer 88
  Information Technology Information Technology Project Coordinator 95
  Information Technology Web Project Manager 96
  Information Technology Geographic Information Systems Analyst 97

 

 

Software Architect becomes the first one to be ranked as the best job in USA and that is amazing! With the capability of people educated from IT sector can pursue career to other industries. There are should be more best jobs in America that available to IT people. :)

 

Have you decide one?

Computer Graphics Assignment Documentation

This is video for Computer Graphics Assignment @ Fasilkom UI

The video is in Indonesian. Enjoy.

Utilizing Windows 7 Virtual Router

It was came to my mind suddenly about how to enable Wi-Fi to be recognized by my Wii. The people at PSE have been told me to not to connect my Wii to internet because of risk of Brick Error Code 003 (your Wii is completely broken, you must change your Wii's motherboard to repair it which equal to buy a new one). FYI, mostly in Indonesia, Wiis are sold in modded version (soft or hard) to enable people played game which sold only Rp.9000,-  (equal to US$ 1) each. I think you what i mean.

Okay, let's get back to the topic. For short, i turn my WiFi on my laptop and then Wii's WiFi. I thought it would be simple to connect since Wii's WiFi recognized my laptop's WiFi but unfortunately it still didn't want to connect. After i googled the problem, i found out that simple ad-hoc WiFi connection won't be able to connect my Wii to my laptop. Wii only accepted connection from WiFi router or using additional USB device called Wii Lan Adapter. Realizing the situation, i started to find out other possibilities such as WiFi virtual router. After several times being googled for the possibilities, then i found one solution regarding my laptop specification which is using Windows 7 Professional Edition. Yup, as long as you are using Windows 7, you can use this solution. Before i write the solution, i'd like to introduce some terms regarding the technology.

Microsoft Virtual WiFi Miniport Adapter
Microsoft Virtual WiFi Miniport Adapter is a technology added to Windows 7 technology layer specification. It is run natively on Windows 7. The technology concept is quite similar to virtualization on common Operating Systems which emulates them and enable them to run side by side. Microsoft Virtual WiFi Miniport Adapter emphasizes the concept of virtualization by emulating WiFi card hardware installed on your laptop/PC then make it available for one or more instances so you can connect other devices to your laptop/PC. The connection which established will be viewed as normal connection from router to client not as client-to-client ad hoc connection. 

Below is the picture regarding the architecture of the technology
Media_httpwwwistarted_neggk

Internet Connection Sharing (ICS)
Being available since Windows 98, the technology makes internet connection sharing in your laptop/PC easier. Let say, you have more than one connection. One is backing up with broadband connection and the other one is a connection between your laptop/PC and your cellphone (connected by bluetooth). But unfortunately, your cellphone doesn't have connection to internet and you want to download an application to your cellphone. ICS will handle situation like this. Just open your Network Connection Setting. Pick your broadband connection and share  its internet connection to your bluetooth connection. If everything goes well, should you have your cellphone connected to Internet too. It makes use of DHCP.

Okay the existing technologies from Windows 7 makes Virtual WiFi possible but unfortunately until the release of Windows 7. Microsoft didn't setup the Virtual WiFi application to make use of the technologies although you can build one on your own using Windows 7 SDK and Visual Studio. Luckily, we don't have to take bloody session for developing the application. This is the solution that i'm looking for to solve my problem above. I found that there is an application being developed exclusively for Windows 7 called Connectify. This application is all that i need and solve my problem. Wii recognize my laptop's WiFi and i can browse the Internet using Opera Browser for Wii.

Here they are step by step using Connectify to build your own virtual WiFi connection.

1. Download the software. The current version is Connectify 1.2
Connectifydownload

2. Install it on your system. You should have it run too. The preview should be like this.
Connectify_view

3. For first time, you won't have any connection profile as shown above which i already had. You must setup it for your own. Connectify provides tool for setting up the connection using the simple wizard.
Connectify_view_wizard

Please click it.
4.Entering the wizard
Media_httpcianuretofi_cukeq
This the welcome page, click next >>
On Wi-Fi Device section you will be given a choice to pick your WiFi card device. In my wizard this section is skipped, i guess because of i only have one device. This picture taken from another blog.
Connectify_wizardname

Give your network a name. Since, i'm using it for Wii then i give SSID called WiiSpot.
Media_httpcianuretofi_iszfj
Set the password
Connectify_wizardsharedconnect

Pick your current connection to be shared. I shared my connection from an ADSL router LAN connection.
Connectify_wizardcomplete

This is the last step on the wizard. You can opted for starting hotspot immediately after closing the wizard or taking your time sharing to others about this application.
5. Voila... Now, all are set up. You can try connect other device to your virtual hotspot. Below, my Wii alread connected to my laptop. I have tried to with Blackberry device and another laptop. They can make use my ADSL internet connection too.
Connectify_connected

I hope it will broad your knowledge and help you too. Feel free to leave your comment.

--------------------------------------------------------------

Ovi Mail: Making email access easy
http://mail.ovi.com

It's time for Posterous

Hi readers,

Welcome to my blog, i don't know why, maybe because i'm moody. Yes, i must confess that i typical of nomad blog, i write where i want to write. Now, i'm giving chance to Posterous for a place to share my thoughts. Moreover, i like Posterous concept which offere simple blogging platform. Therefore, i'd like to gain my interest in writing again... Keep in touch...

note: i omitted to abandon my blog @ brutefoz.com domain and its domain.. so please say goodbye and join my new blog...

Regards,

Oz

Getting Started: Prolog (SWI-Prolog)

After wrote part I, i forgot that it should be a tutorial for installing and running (or compiling) prolog source code. In advance, we will use SWI-Prolog, a free software of prolog environment licensed under LGPL, which can be downloaded here. The distribution came into binaries and source for multi-environment operating system. It is your choice to use the pre-compiled one instead of building the source code first.

SWI-Prolog is widely use for education, research, also for comercial purposes. It offers some main features, such as:


If SWI-Prolog has been installed into your system and you ran it. You will see interface like this:

Media_httpphotosfakfb_wfbdn

Okay… you just successfully set up your logic programming environtment and ready to be used. Now, we shall move on next step. Running your first program.

So we have this source as our very first prolog source code program. It is based on these knowledges/facts:

man(budianto).
man(denvil).
woman(felicia).
woman(ivon).

By using your favourite text editor you can rewrite the source code above. The next step is save your source code under extension *.pl. Please follow these steps to compile and run your first program:

1. After open SWI-Prolog. Click File > Consult…

Media_httpphotosfakfb_wphhh

The purpose is for linking SWI-Prolog with your pre-written prolog source code.
2. Choose your prolog source code. Please choose the one contains the source above.
Media_httpphotoseakfb_fjmdr

Click Open.
3. As you Open. SWI-Prolog will compile it into its knowledge-based database. Your program is ready to be queried after it has been compiled.
Media_httpphotosbakfb_rwrdl

4. Let’s we try first query to make sure everything is going alright. Yet, we know that felicia is a woman from the facts. We can verify the knowledge in database is valid by querying whether felicia is a woman or not by this syntax.

?- woman(felicia).

as noted in screenshot below

Media_httpphotosaakfb_dzcih

as you can see SWI-Prolog replied yes to the query. It means that it found the knowledge that stated “felicia is a woman” from its knowledge-base database.

Enjoy…

Prolog: representing a clause

Dear iTech reader,

In next semester, i will take course on Logic Programming using prolog. Logic programming is a family of declarative-type programming. Why declarative? It is because prolog represents problem in declarative statements based on goals. It is also known as the goal-oriented.

So this is my first program taken from Ivan Bratko’s book: Prolog: Programming for Artificial Intelligence. Some have been rewritten also to help myself understanding prolog. 

Representing a clause in Prolog

We have this clause:

“Budi is playing footbal”

We can rewrite it in Prolog as:

play(Budi,footbal).

We should notice something. As declarative-type programming, prolog isn’t suited for numeric computation. Therefore, it is best-suited for solving problem which is involving relation between objects. For example: family tree relation.

Statement:

For all X and Z,

X is a mother of Z if
X is a parent of Z.
X is a female

 

mother(X,Z) :- parent(X,Z),female(X).

At the snipped prolog code above. First, we define relation by facts: X is a parent of Z and X is a female. Second, we define relation mother by rule of first facts. Comma (,) is a sign of conjunction of the conditions which relation should be satisfied if both true.

Exercise (Ivan Bratko,13):
a. Everybody who has a child is happy (introduce a one-argument relation happy).
b. For all X, if X has a child who has a sister then X has two children (introduce new relation hastwochildren).