Practical Web Programming

Monday, December 31, 2007

2007 Make Money Online Review

It's been more than one a half year since I started my campaign to make money online through Adsense. The seed was planted when a co-worker introduced me to Adsense. Since then I received three payout check. My latest was just last November. And now I'll be passing again the 100 dollar mark, so I'll be expecting again a payout this January.

Goal

My goal to make 10 dollars per day with Adsense last 2007 was not realized but I'm doing fine and my earnings per day is increasing. So I'll just carry out that goal to this year, 2008.

In the effort to increase my earnings, I sorted to other revenue stream like Payperpost and text link ads and I also made good revenue with it, almost 70 percent of my Adsense income last year.

Strategies for the Year

Although I'm doing fine with my revenue, it's still not half of my goal income for Adsense. The problem with me is I tend to "bite more than I could chew". I maintained many blogs and websites that I can't give all of it proper attention. I know SEO a bit, so instead of aggressively marketing my websites, I rely mostly in search engines. So this year, 2008, I'll be marketing my websites more instead of relying in search engines. I'll also divide my time between my website to give more focus to it.

Visual Basic: How To Automatically Drop Down Combo Box

Here's a code snippet on how to automatically drow down the combo box control in Visual Basic 6 without using an API

'-->HOW TO AUTO DROPDOWN A COMBO WITHOUT USING API FUNCTION
Private Sub Combo1_GotFocus()
SendKeys "%+{DOWN}"
End Sub

Wednesday, December 26, 2007

9 More Way To Boost Traffic To Your Website

Here are 9 more ways that you can do to increase more traffic to your website. Read on...

1) Writing a Series of posts like this one, keep your readers captivated by continuing on with a series. Try to be original, if you find out about a new product or service try to blog about it first.

2) Write Product Reviews, I quite like this one. Write honest reviews of other peoples products then ask for a link.

3) Write Lists, like the top ten or top twenty or even top 100 best ways to do something. These attract links like crazy when done right. They also usually do well on social networking sites like Digg or Stumbleupon.

4) Comment on other peoples blogs, try & strike a relationship with other bloggers in your niche or topic. Once you build up a relationship you can exchange links or even ask for them to post about one of your recent entries & vice versa.

5) Write Articles & publish them on article directories. Include links to your blog in the resource box. Make sure & use relevant anchor text like Earn Money Blogging etc

6) Add links to your site on Wikipedia in the relevant section. So for example if your site if about pottery, add a link to your site in the relevant section. Sometimes the links get deleted if they don’t deem your site relevant enough, but sometimes the links stay & give good traffic

7) If you sell a product creating an affiliate program can drastically increase your exposure & also increase your incoming link count. Provided you use an SEO Friendly Affiliate Program.

8) Include options on your site that allows visitors to email articles to friends, vote for articles & generally participate more. This will increase the chance they will recommend your site or mention it to someone else.

9) Claim your blog on Technorati & include an “Add to Favourites” button on your sidebar. The more popular your blog becomes, the more people will add it to their favourites.

Sunday, December 23, 2007

Merry Christmas To All

Monday, December 17, 2007

12 More Ways To Increase Website Traffic

If you're struggling to increase traffic to your website or blog, here's another tips I can share with you. Read on.

1. Create A Press Release. Creating a press release about your website will encourage curiuosity and will persuade others to visit your website.

2. Sell Your Product On Ebay. Ebay is a hotbed of shoppers. They’re already ready to buy. Simply put your product in front of them and you’ll get new sales. In this lesson, I’ll reveal the key mistakes most people make when advertising their products… and how to pump maximum profits out of Ebay.


3. Sell Your Product On Amazon.com. Amazon is another hotbed of shoppers. People visit Amazon ready to buy products.

4. Sell Your Product On Froogle. Froogle is yet another little-known hotbed of shoppers. At this site, visitors come with credit card in hand and in ready-to-buy mood.

5. Start A Blog. Google loves Blogs. It’s a surefire way to increase your targeted traffic.

6. Post Comments On Other Blogs. Another way to immediately start driving more traffic is to simply post meaningful comments on other people’s blogs.

7. Write A "How-To" Report. Generate meaningful traffic simply by writing a how-to report about your product or service.

8. Get Others To Promote Your Site For You. Recruit affiliates and other partners and offer them a good incentives for bringing traffic to your websites. Incentives can be cash or free ebooks or services.


9. Write Regular, Impactful Articles. This is one of the most powerful, free strategies you can use to get targeted traffic.

10. Turn Your Ebook Into An Audiobook. This one is really a no-brainer. And it takes just a few minutes. Not everybody likes to sit at the computer and read. More and more, we’re finding that people prefer to purchase audiobooks that they can take “on the road.”

11. Convert Ebooks Into E-reader Format. This is another untapped niche. Traditional ebooks can’t be read on PDAs and other such devices. But the demand is there, and people who can afford PDAs and other such gadgets have money to spend.

12. Get Links From Other Relevant Sites. By trading links with other relevant sites, you can dramatically increase your traffic and search rankings (link popularity is one of the key factors that Google looks for).

Thursday, December 13, 2007

How To Generate Website Traffic Using Free Methods

While there are ways to jumpstart your traffic flows, many sites don’t have the resources that others have to generate more traffic for your site. Well, you don’t have to spend a cent; all you need is the proper mindset and a lot of eagerness. You also must have the drive and perseverance to do hard work and research to generate more traffic for your site.

How sweet it is to have more traffic for your site without spending a single cent. Now it’s a sure thing that many sites have articles that offer tips and guidelines in how to generate traffic using only free methods. Because it is possible, you don’t need to speed a single cent, it may take time, to say honestly, I’m not going to beat around the bush with you. You get better chances by paying for your advertisements, but at least you get a fighting chance with some of these free methods I’m about to tell you.

Take advantage of online forums and online communities

The great thing about forums and online communities is that you can target a certain group that fits the certain demographic that you are looking for. You can discuss about lots of things about the niche that you represent or offer. Another great advantage is that you know what you are getting into and you will be prepared.

Build reputation in online communities and forums

Show them what you are made of and wow them with your range of expertise about the subject, with that you can build a reputation and build trust with the people in your expertise and knowledge.

Make your own newsletters

Provide people with a catalog of your products and interesting and entertaining articles. If you make it really interesting and entertaining, more people will sign up for your newsletter and recommend it to other people. The more people who signs up for your newsletter, the more people there will be that will go to your site increasing your traffic.

Trade links with other similar sites

You don’t have to spend a cent. All you have to do is reach an agreement with another webmaster. With exchanging links, the efforts both sites do will benefit both sites. Every traffic that goes to the site could potentially click on the link of your site and visit your site as well. This works well especially when both sites feature the same niche.

Write articles that could pique the peoples attention

Try writing articles that will provide tips and guides to other aficionados. Writing articles that provide good service and knowledge to other people would provide the necessary mileage your traffic flow needs.

Submit your articles to article directories

When people find interest in your articles they have a good chance of following the track by finding out where the article originated. Include a link or a brief description of your company with the article and there’s a great probability that they will go to your site.

Write good content for your site

Many search engines track down the keywords and keyword phrases your site uses and how they are used. It is not a requirement that a content should be done by a professional content writer. You could do your on but you have to make content for your site that is entertaining as well as informational. It should provide certain requirements as well as great quality.

Generally, internet users use search engines to find what they are looking for. Search engines in return use keyword searching in aiding their search results. With the right keywords, you could get high rankings in search engine results without the costs.

All of these methods and more will drive more traffic to your site for free. All it takes is a bit of effort and extended man hours. Learn all you can about the methods depicted here and you will soon have a site with a great traffic flow without the usual costs that come with it.

Tuesday, December 11, 2007

5000 Visitors and Counting

This blog reaches another milestone today. It recorded more than 5000 visitors as of this writing, and still counting. This is because of my Top 25 Explanations by Programmers post which I submitted to Digg last December 8. It was only dugged 12 times, but when aroman07 and wuzetez submitted it to wykop and dzone, the traffic started to soar even higher.

My Sitemeter Log


Traffic from social bookmarking websites is not permanent. It has it's ups and downs depending to how interesting your post is.

Well, I think I ought to write more interesting posts if I want to keep up this kind of traffic. Hhmmm, what's next? (think, think, think)

Monday, December 10, 2007

Is This The End of Agloco?

Today, I received an email from Agloco (I think all members do). Is this is a sign that Agloco is going down.

We would like to update you on the status of AGLOCO's operations. We continue to believe in the AGLOCO concept, but our revenue is currently not sufficient to give Members a meaningful distribution. And though there are increases in membership, the resulting revenue is not enough to support operating costs. As a development team we are unable to continue to use our savings to fund the operations. If any Member would like to pursue continuing the operations of AGLOCO, you may contact us at agloco1@live.com .

We would like to thank every Member for supporting our effort to bring a piece of the Internet directly to the user. We hope that we can find a way to keep the operations going.

AGLOCO Development Team


Accumulated Hours and Members



This is my accumulated hours and network members as of today. I can still remember when I signed up for this. I was hopeful at that time that this will earn me money.

My friends and officemate would be disappointed with this news. I was the one who introduced and invited them to this program. They were also hopeful that this will become profitable.

Well, I just hope this is not going to end like this.

Sunday, December 09, 2007

How To Export To OpenOffice Spreadsheet (Calc) in VB6

Exporting data to MS Excel is relatively easy. But if you are an advocate of Opensource software, you maybe using OpenOffice instead of Microsort Office.

This visual basic source codes show how to export the contents of the MSFlexGrid into OpenOffice Calc spreadsheet.

To test this source codes, open a Visual Basic 6 project add the ff. controls to a form: an MSFlexGrid, a CommandButton. Then, copy and paste the source codes to your project and you're good to go.

Public Sub ExportGridToCalc(grdTemp As MSFlexGrid, _
strTitle As String, _
Optional lngStartRow As Long = -1, _
Optional lngEndRow As Long = -1, _
Optional lngStartCol As Long = -1, _
Optional lngEndCol As Long = -1)

Dim oSM As Object 'Object for accessing OpenOffice
Dim oDesk As Object 'Objects from the API
Dim oDoc As Object 'Objects from the API
Dim oSheet As Object 'Objects from the API
Dim arg() 'Ignore it for the moment !
Dim lngRow As Long
Dim lngCol As Long

'-->SET FIRST THE ROWS AND COLS
If lngStartRow = -1 Then lngStartRow = 1
If lngEndRow = -1 Then lngEndRow = grdTemp.Rows - 1
If lngStartCol = -1 Then lngStartCol = 0
If lngEndCol = -1 Then lngEndCol = grdTemp.Cols - 1

'Instanciate OOo : this line is mandatory with VB for OOo API
Set oSM = CreateObject("com.sun.star.ServiceManager")
'Create the first and most important service
Set oDesk = oSM.createInstance("com.sun.star.frame.Desktop")
'Create a new doc
Set oDoc = oDesk.loadComponentFromURL("private:factory/scalc", "_blank", _
0, arg())
'Get the first sheet in the doc
Set oSheet = oDoc.getSheets().getByIndex(0)

Call oSheet.getCellByPosition(0, 0).setString(strTitle)
For lngRow = lngStartRow To lngEndRow
For lngCol = lngStartCol To lngEndCol
Call oSheet.getCellByPosition(lngCol, lngRow + _
IIf(lngStartRow = 0, 2, 1)).setString(grdTemp.TextMatrix(lngRow, _
lngCol))
Next
Next
End Sub

Private Sub LoadDataToGrid()
Dim lngRow As Long
Dim lngCol As Long

With MSFlexGrid1
.Rows = 11
.Cols = 5
.FixedCols = 0

For lngRow = 0 To 5 - 1
.TextArray(lngRow) = "Header " & lngRow + 1
Next

For lngCol = 0 To 5 - 1
For lngRow = 1 To 10
.TextMatrix(lngRow, lngCol) = "R " & lngRow & " - C " & lngCol + 1
Next
Next
End With
End Sub

Private Sub Command1_Click()
Call ExportGridToOOCalc(MSFlexGrid1, "Exporting to OpenOffice")
End Sub

Private Sub Form_Load()
Call LoadDataToGrid
End Sub

Friday, December 07, 2007

Top 25 Explanations by Programmers...

...When their programs don't work.

1. Strange...
2. I've never heard about that.
3. It did work yesterday.
4. Well, the program needs some fixing.
5. How is this possible?
6. The machine seems to be broken.
7. Has the operating system been updated?
8. The user has made an error again.
9. There is something wrong in your test data.
10. I have not touched that module!
11. Yes yes, it will be ready in time.
12. You must have the wrong executable.
13. Oh, it's just a feature.
14. I'm almost ready.
15. Of course, I just have to do these small fixes.
16. It will be done in no time at all.
17. It's just some unlucky coincidense.
18. I can't test everything!
19. THIS can't do THAT.
20. Didn't I fix it already?
21. It's already there, but it has not been tested.
22. It works, but it's not been tested.
23. Somebody must have changed my code.
24. There must be a virus in the application software.
25. Even though it does not work, how does it feel?

I think I'm guilty of some of this. (^_^)

See also:
10 Type Of Girls in the IT World
Drawbacks of being a programmer

Never Give Up

A funny yet inspiring picture that I found from the net. I wonder which of the two will give up. (^_^)

Thursday, December 06, 2007

Make Money Online with SponsoredReview

Here's another way to make money online from your blog, SponsoredReviews.com. Like PayPerPost, SponsoredReviews also offers bloggers a chance to make money from there blog, doing reviews about products, services and websites by advertisers.

How Much Can I Earn?
Good question. With SponsoredReviews, you set your own price. Depending on the size of your readership/visitors and the quality of your blog posts, you can earn anywhere from $10 to $1000 per review. If your blogs is big in terms of visitors and pageviews monthly, you might be able to get even more.

Payment Period
You will receive your outstanding earnings two weeks after your review is completed via PayPal. So you need to sign-up first to PayPal before joining SponsoredReviews. You can check your payment history and a summary of your outstanding earnings on our site at any time via your control panel.


Also For Advertisers
SponsoredReviews is not only for bloggers, but also for advertisers. If you want to launch a new product or service, create buzz about your new website, get constructive feedback from bloggers and build high quality links, you can also do it here.

Monday, December 03, 2007

Uncommon Ways to Increase Website Traffic: Blog Comments

Blogs are everywhere today in the Internet. In fact there are more than a hundred millions of blogs today and more than a hundred thousand are being built everyday.

Blogs has a comments section, except it the owner disables it. Bloggers use comments to interact with each other and use it to make a "connection" to thier readers. Others use it as a medium to ask for a link exchange - as I have done and still doing. And many more.

So What's in a Comment? How Can I Gain Traffic From It?

Most blogging engine, especially Wordpress, allows you to put your name, email address and your website link in the comment section. Others like Blogger, only allows comments and the default link to you profile. But regardless what blogging engine, you can put your links in the comment area.

See below for some benefits you can gain from commenting to blogs.

1. Search Engine Optimization

Search result ranking of search engines like Google, is based on many factors. One of them is the number of links and anchor text consistency to a website. The higher the number of link and the consitency of the anchor text, the higher you go up to the search result page.

One good example is the word "here". Make a google search of that word and you will see that the number one in the result page is the Adobe Reader Download. There is no connection of the word "here" with Adode, but since most website owner use the word "here" to direct their users to the Adobe download page, Google's search algorithm think it is relevant to the website and so puts it to the top.

2. Exposure
One way to increase your traffic is to make others know that your site exists. Putting your link in comments is one way to do it. This really works as some visitors are curiuos about the blogs visitors and they are enticed to click your link.

3. Connection
As I said earlier, you can make a connection to other bloggers by using comments. Once your connections are stablished, it becomes easy for you to promote your other websites to other bloggers.

Summary
Commenting in other blogs is a good way to promote you website and to letting others know that you (and your website) exist in this virtual world. It also helps you form connections with other bloggers.

Two important notes is to always use the same anchor text everytime you put your link. And to be sensible always in your comments so that blog owners will not delete it.

Sunday, December 02, 2007

TV, Source of Information and Violence

Television is really a powerful form of communication. With millions of people watching the television everyday, no wonder TV ads are so expensive especially during primetime. There's the news, drama series, home shopping and a lot more . Remember the as seen on tv products or services? Well, as the name suggest, they all first seen on TV.

But do you know aside from being a source of knowledge, TV is also a source of violence? According to statistics, the average child will watch 8,000 murders on TV before finishing elementary school. And by age eighteen, the average American has seen 200,000 acts of violence on TV, including 40,000 murders.

Well, if you are serious about protecting your child against violence, you should limiting the TV viewing time. Just my two cents.

Uncommon Ways to Increase Website Traffic: Community Websites

Community websites are common these days. Some very popolar are friendster and myspace and there are thousands more out there which slowly becoming popular also. Doing a Google search will literally gives you hundred of thousands of it.

Most, if not all, community websites allows you post bulletins and blogs and to message anybody in the community. Community websites are not only good for socializing and contacting your old friends and colleagues. They are also a good traffic source for your website.

Imagine if you can post bulletins and you have thousands of members/friends in that community. That's automatically thousands of backlinks to your website as well. If your members/friends are targeted, which means their interest is the same as your website's theme, there is a big chance that they will read your bulletins and click your link to your website. And if you write good posts, they will surely come back for more, maybe for weeks or years, and chances are, they will tell their peers about your website and the process will repeat itself - a powerful viral marketing technique.

Tips When Joining a Community Websites:

1. Pick Between One to Three. Don't join all the community websites out there. That will too time consuming and difficult to maintain. Pick and join only the top three websites.

2. Regularly Add Friends. Keep in mind that the more friends you add, the more potential traffic to have for your websites. Regularly add friends to your profile.

3. Join Groups of Your Interest. Joining groups within your interest and website's content will keep your friends targeted. And they are more likely read your bulleting posts.

4. Don't Spam. Don't post bulletins that are of no value and don't overpost. Make sure that your post will help or inform your friends of something in one way or another.

Saturday, December 01, 2007

Computer and Coffee

I'm a big coffee drinker, I admit that. I guess aside from a computer, coffee is another tool for a programmer. Especially if you lack sleep, sitting there in front of the PC without a cup of coffee is like sitting in your bed. (^_^)

At the office I drink two to three cups of coffee. We have coffee makers but I like 3-in-1 coffee instant coffee more because homemade coffee gives me hyperacidity.

At first, drinking more than two cups of coffee worries me, after I read the health benefits of it, I hungry for more. Here are some benefits of coffee: lower your risk of diabetes, Parkinson's disease, colon cancer, lift your mood and treat headaches.

PC Clean-up

It's really good to have your tool storage always organize and handy because you'll never know when you will need them.

Today, I cleaned up my home personal computer. Problem is, I can't found my paintbrush that I use to clean up the inside part of my PC and the keyboard. I can't remember where I put the last time I used it. I may have put it in other place and forgot to get it back and return to my storage. I'm an organize type of person but sometimes forgetful. I ended up using just the vacuum cleaner to clean my PC.

It's been almost two months since the last time I cleaned my personal computer. My blogging and effort in making money online campaigns really took most of my time that I forgot to pay attention to the tool I'm using, my beloved PC. Good thing that PC don't have feelings. (^_^)

Friday, November 30, 2007

Find of the Day: An Extraordinary Blog

While digging through the internet this morning, I came across with this blog, The XO Directory. True to it's description, "A directory of eXtraOrdinary things", I did find and read in this blog offbeat/odd news, world records, and many extraordinary things. The owner of this blog may have comb the entire internet everyday to find this extraordinary things.

The blog is fairly new, having been started just last month. But I'd probably come back here often to find extraordinary things. It pays to have extraordinary knowledge on extraordinary things.

Search Engines Infected by Hackers

It appear that the saying that "Christmas is a season of Love and Crime" is also true in the internet. Just recently, Google Yahoo and MSN search engines have been infected by hackers.

Users who uses this search engines is fooled into visiting malicious websites crammed with malware.

The websites, which came up in results for innocuous terms such as "Christmas gifts", "infinity" and "hospice", contained software that exploited vulnerabilities in Internet Explorer.

Visitors to the booby-trapped sites faced having their computer taken over and personal data stolen.


Hackers have exploited the coming Christmas season by targeting and exploiting the keyphrases "Christmas gift shopping", "Christmas holiday sale" and "holiday shopping fun".

Google have removed the websites from the search results after they had been appearing in searches, but it is believed the websites are still cropping up in Yahoo and MSN Live searches.

Thursday, November 29, 2007

My Third Adsense Payout

Yesterday morning when I signed-in to my Adsense account, I learned that my third Adsense payout has already been sent via Western Union. That day after office I went to Victoria Plaza mall to get it.

Good thing that Goggle decided to team up with Wester Union. The payout that takes almost a month before, now takes just one day for you to get it. My payout was sent on the 26th of this month but I didn't check my payment tab in my Adsense account so I just got it yesterday.

This third payout, which amounted to $104.61 (4,455.33 in Peso), is enough for me to buy a new wristwatch this Christmas. Maybe I'll wait until middle of December. There's a lot of sale by then. I might get a Casio watch for a lesser amount.


It was the last week of October when I passed my third 100 dollars mark. After this payout, I still have 40 dollars in my Adsense earnings. It will be carried to my next payout. I hope it will be on January next year. (^_^)

Recharged Camera

It's really hard to have a camera without a rechargeable battery. So yesterday, after my office, I finally bought a nimh batteries for my sony digital camera. My camera has long been idle because I have no new batteries cells.

Before buying this rechargeable batteries, I used up eight ordinary batteries (I seldom use my camera lately, only in especial occasions) since I bought this last June. Counting the battery cost, I decided to buy a rechargeable one instead.

At one thousand pesos, the four batteries including the charger, I think it's a bargain. Good thing that I finally received my third Adsense payment from Google via Western Union.

Wednesday, November 28, 2007

Goodbye PageRank

Now I know why my pagerank went from two to a flat-faced zero. It was on Now 14 that Google made their infamous update to their pagerank algorithm. After that day, millions of bloggers see great decrease in their pagerank, especially those who are selling links and doing sponsored post in their blogs - such as this blog. Some said it was a good step to rid the blogsphere of link spammers and sponsored posters. Some criticized Google for monopolizing the web. I choose to say nothing, and just keep on blogging.

Seeing my pagerank like a yoyo in just a month, I don't care much about it now as much as before. As long as I enjoy and make money blogging, I'm going to keep on blogging. After all, RealRank is coming.

Tuesday, November 27, 2007

Family Safe Blogging

If you can't decide what topic is for adult and what is not, this latest post from the Adsense blog might help you.

Many of our publishers regularly ask what is exactly considered adult or mature content by AdSense policies. It's a lot easier to understand when we speak about family-safe content. As you may already know, only ads classified as family-safe will be displayed on AdSense publisher websites.

Our policy regarding adult or mature content may include any material that is not appropriate for all audiences. While this obviously includes full nudity or sexual activity, it may also include textually explicit sexual content, image or video content containing lewd or provocative poses, strategically covered nudity, see-through or sheer clothing, and close-ups of anatomy that would be inappropriate if shown nude. Additionally, topics such as sexual health and sex tips may be held to a higher standard of professionalism than content that isn't bordering on mature.

While it's not a sure test, we sometimes suggest that publishers ask themselves the following questions to determine if content is family-safe: Would I be comfortable viewing this content with my parents or children in the same room? Would I feel comfortable viewing this content if my boss walked up behind me while I had this content on my screen? If the answer to either of these questions is no, then it is likely that some advertisers would not be comfortable showing their ads on such content and we might consider it mature.

Posted by Guillermo Bracciaforte - AdSense Publisher Support

Monday, November 26, 2007

Achy Monday

This morning I woke up with a headache. Blogging to the max really is not good for your health. Last Saturday and Sunday I didn't had a good night sleep because of fiddling with my blogs and websites. My headache was so bad that even the ceiling lighting of our office irritates me. Because of the headache, I took the afternoon today off. I planned to do it in the morning but I realize we have this Christmas every Monday morning so I was forced to go to work so as not to be busted with my nickname.

Aside from lack of sleep, I think it was the junk foods I gobbled last weekend that triggers my headache. I heard from the TV before that MSG can trigger migraine (some junk food has it). Well, to much blogging and too much MSG certainly can cause severe headache. Maybe I'll bring the remaining junk foods to the office and share with my officemates.

Sunday, November 25, 2007

Sunday Boxing

Yesterday, after doing my weekly cleaning of the house, I watched the boxing match between Mayorga and Vargas. I have seen Mayorga fought before but not Vargas. My early impression is Mayorga will going to win the fight, and he did.

I didn't see Mayorga won because I got tired because the TV's signal was not good yesterday. But if it was on an LCD TV, I'd probably finish watching the fight regardless of the signal - but I'm not picky with TV (^_^). I learned of the result just this morning from an officemate of mine.

Saturday, November 24, 2007

Weather Sick

This past few days, the weather is really taking it's tool on me. Last Wednesday I had an "affair" with the flu. Good thing our office has medical supplies always in store for the employees. My flu didn't made me took day-offs but it hinders me from going to my regular gym time (after office hours).

At this time typhoon Mina (international codename Mitag) has slightly moved faster northwest of the country to hit the provinces in Region 2.

In its 5 a.m. bulletin, the Philippine Atmospheric, Geophysical and Astronomical Services Administration (PAGASA) reported that the typhoon has continued to veer toward Northern and Central Luzon.

The weather bureau spotted the center of the typhoon around 4 a.m. 140 kilometers, north northeast of Virac, Catanduances or 290 kilometers Southeast of Casiguran, Aurora, moving with 15 kph northwest.

Friday, November 23, 2007

Google Adsense Ads Redefined

If you haven't noticed it yet, guys at Google made a new update in Adsense ads. They said this new update will lessen the accidental click that some site visitors commit when visiting a website or blog. This latest update caused Adsense publisher's eyebrows to rise (including mine).

Earlier this year we stepped back to examine the value users, advertisers, and publishers derive from clicks on content ads. As you integrate ads with your site's content and navigation, we want to ensure a positive user experience. We identified a few areas for improvement and began implementing changes, starting with our new ad formats in April.


Before this update, Adsense ads are clickable anywhere in the ad unit, but now, only the title of the ad and the url is clickable (see image below). This means that many publishers may see their clickthrough rate drop from this point on.


Read the full article here.

Thursday, November 22, 2007

An Insured Day

Yesterday I found myself buying a whole life insurance over the phone. It was the third time that the telemarketer of my HSBC credit card called in the past two months or so. The coverage started immediately after we finished talking on the phone.

The insurance policy program I bought called iProtect, a partnership of HSBC and PhilamLife, cost Php300+ per month (I can't really remember the exact amount). They said that it will be automatically charge in my credit card and appear in my monthly billing. The total policy amount is 4 million for me and my wife and will cover death, permanent disability and body part dismemberment.

I have yet to see and read the whole policy which will arrive two weeks from now. If I'm not impressed, I maybe cancel it and look for another one.

Wednesday, November 21, 2007

How To Make Custom Messages in VB6

If you are a Visual Basic (VB6) programmer who finds displaying messages using the MsgBox function so tedious. The functions below will make your life easier.

I wrote this functions to answer my demands in displaying messages to the users of my programs. This function is very handy. In fact, almost all of my Visual Basic projects uses this functions.

This functions re-uses the Visual Basic's MsgBox function to create custom message functions that are more flexible and easy to use.

'-->enum for the return of the confirmation from the user
Public Enum enum_prompt_return_value
pr0mpt_yes = vbYes
pr0mpt_no = vbNo
End Enum

'-->system name variable desclaration
'-->ex: gsystem_title = "payroll system"
Public gsystem_title As String

'-->this sub will display the critical error
'-->using the error object passed to it
'-->usage : call criticalerrormsg(err, ["error"])
Public Sub criticalerrormsg(err As ErrObject, _
Optional strtitle As String = "critical error")
MsgBox err.Number & ": " & err.Description, vbCritical, _
gsystem_title & " - [" & strtitle & "]"
End Sub

'-->this sub will display the error using the
'-->error object passed to it
'-->usage : call errormsg(err, ["error"])
Public Sub errormsg(err As ErrObject, _
Optional strtitle As String = "error")
MsgBox err.Number & ": " & err.Description, vbExclamation, _
gsystem_title & " - [" & strtitle & "]"
End Sub

'-->this sub will display an information message
'-->using the text passed to it
'-->usage : call infomsg(err, ["info"])
Public Sub infomsg(strmessage As String, _
Optional strtitle As String = "info")
MsgBox strmessage, vbInformation, _
gsystem_title & " - [" & strtitle & "]"
End Sub

'-->this sub will display an information
'-->message using the text passed to it
'-->usage : call infomsg(err, ["info"])
Public Sub alertmsg(strmessage As String, _
Optional strtitle As String = "alert")
MsgBox strmessage, vbExclamation, _
gsystem_title & " - [" & strtitle & "]"
End Sub

'-->this sub will ask a confirmation from
'-->the user using the text passed to it
'-->usage : retval = confirmmsg("delete record?", ["confirm"])
Public Function confirmmsg(strmessage As String, _
Optional strtitle As String = "confirm") As _
enum_prompt_return_value
confirmmsg = MsgBox(strmessage, vbQuestion + vbYesNo, _
gsystem_title & " - [" & strtitle & "]")
End Function

Sunday, November 18, 2007

My PageRank is Back to Zero

It was last week of October when I noticed the my pagerank increased to two. And now, just after three weeks, about two days already, my pagerank is back to zero again. Maybe it's true that Google's latest pagerank update is meant to penalize sites with excessive paid links. If this is true, maybe that is the reason because I ran PayPerPost in this blog. But this will not stop me from doing post sponsored by PayPerPost because even those are sponsored, I can say that I honestly give my opinion in every post, sponsored or not.

Friday, November 16, 2007

How To Limit The Cursor Movement in VB6

Limiting the cursor movement in a certain area (Ex: a form) can be restrictive to your users, but sometime certain application requires it. This codes show how to limit the cursor movement within a form or any control in Visual Basic 6.

To test it, just open a Visual Basic project with a form in it. Copy the sourcecodes and paste to the declaration section of the form. Then put two command buttons in the form.

You can limit the cursor movement within any control in Visual Basic. Just change the 'Me.hwnd' with the control's hwnd property. Ex: Command1.hWnd

'-->API Declaration
Private Declare Sub ClientToScreen Lib "user32" _
(ByVal hwnd As Long, lpPoint As POINT)
Private Declare Sub ClipCursor Lib "user32" (lpRect As Any)
Private Declare Sub OffsetRect Lib "user32" _
(lpRect As RECT, ByVal X As Long, ByVal Y As Long)
Private Declare Sub GetClientRect Lib "user32" _
(ByVal hwnd As Long, lpRect As RECT)

Private Type RECT
Left As Integer
Top As Integer
Right As Integer
Bottom As Integer
End Type

Private Type POINT
X As Long
Y As Long
End Type

Private Sub Command1_Click()
Dim Client As RECT
Dim Up As POINT

ClientToScreen Me.hwnd, Up
GetClientRect Me.hwnd, Client
OffsetRect Client, Up.X, Up.Y
Up.X = Client.Left
Up.Y = Client.Top
ClipCursor Client
End Sub

Private Sub Command2_Click()
ClipCursor ByVal 0&
End Sub

Private Sub Form_Load()
Command1.Caption = "&Limit Cursor"
Command2.Caption = "&Remove Cursor Limit"
End Sub

Thursday, November 15, 2007

How To Handle Null Values in Database in VB6

Null value is just so frustrating. If you don't anticipate and handle it, it will create unpredictable results in your program. With null values unhandled, runtime error are very likely to occur.

If you are a business application programmer, you need to take null values seriously, especially when accessing and referencing data from a database. In my experience as a programmer, this is one of most causes of runtime error in programs written by newbie (even experienced) programmers.

This function help you in handling null values from a database. It will checks a value for null and returns a non-null value or a default value.

'Language: Visual Basic 6 (VB6)
'Parameter: varValue = the value that needs to be handle
' varNullValue = the optional value to return in
' case the varValue is Null
'Usage: MsgBox IfNull(rst!name, "kabalweg")


Public Function IfNull(varValue As Variant, Optional varNullValue As Variant = "") As Variant
If IsNull(varValue) Or varValue = "" Then
IfNull = varNullValue
Else
IfNull = varValue
End If
End Function

In The Formatting Table

It's been three days now that my office PC is in the formatting table of our company's computer technician. The problem was I can't load maps and the development suite that I use for development won't re-install. So I decided to have it formatted.

At first I thought it was a problem in the operating system that caused errors when loading maps during development and running programs. It was only yesterday that I found out that it was my Zenworks account, that may have been changed by guys at out network department, that was the culprit.

All went well yesterday but when my sourcesafe started to annoy me, I decided to re-installed the Visual Studio 6 that I use for development. But then again the installation kept giving me errors so have it re-formatted again. This afternoon I got it back but the Oracle client is missing. Maybe I have to spend again the whole morning tomorrow fixing it. This is a wrong timing because I have to fix a program for COLIGHT which need to be finish before end of next week.

Tuesday, November 13, 2007

Apple Roadshow Featuring Mac OS X Leopard

Last night, me and two of my officemates attended the Microwarehouse sponsored Apple Roadshow which features Apple's newest sensation, the Loepard OS. It was a two-birds-in-one-stone event for me. It was the first time I attended presentation like it, and the first time I entered Davao's premiere hotel, the Marco Polo. Yes, living in Davao for almost nine years, it was surprising I haven't in that hotel before last night. It's something I'm not proud of. (^_^)

The venue was nice, the food was superb (it was free), and the software presented was great, but the presenter was somewhat the opposite. I think he was not so familiar with the Loepard operating system. In fairness to him, the Loepard OS was launch in the Philippines just days ago, so he may be on the process of familiarizing the software.

Some Pictures

How To Import Text File To Excel in VB6

This visual basic source code shows how to import a text file into a Microsoft Excel file.

To test this source code, add a blank Excel file named Phones.xls and a text file named 'Phones.txt' with the following text:

"Ali Ezzahir","Winnipeg","Canada","Programmer","204-1234567"
"Adam Smith","Winnipeg","Canada","Carpenter","204-8970965"
"John Smith","Winnipeg","Canada","Engineer","204-6578765"

This text is what we will import to the Phones.xls. Now open a Visual Basic project. In the form, add a commandbutton control and paste the source codes below, then run the program and click the commandbutton.

'Procedure: N/A
'Language: Visual Basic
'Parameter: N/A
'Purpose: Import text file to excel file
'Usage: N/A

'-->API DECLARATION
Private Declare Function ShellExecute Lib "shell32.dll" Alias _
"ShellExecuteA" (ByVal hwnd As Long, _
ByVal lpOperation As String, ByVal lpFile As String, _
ByVal lpParameters As String, ByVal lpDirectory As String, _
ByVal nShowCmd As Long) As Long

Private Sub Command1_Click()
Dim xlApp As Excel.Application
Dim xlsWorkBook As Excel.Workbook
Dim xlsWorkSheet As Excel.Worksheet
Dim J As Integer
Dim delim As Variant
Dim LineText(8) As String
Dim NewLine As String
Dim CC As String
Dim DD As String
Dim AA
Dim I As Integer
Dim W As Integer
Dim Z As Integer
Dim ReturnCode As Integer

Me.MousePointer = 11
DD = """"
On Local Error Resume Next
Set xlApp = New Excel.Application
Set xlsWorkBook = xlApp.Workbooks.Add
Set xlsWorkSheet = xlsWorkBook.Worksheets.Add

delim = vbTab

xlsWorkSheet.Cells(1, 1).Value = "Name"
xlsWorkSheet.Cells(1, 2).Value = "City"
xlsWorkSheet.Cells(1, 3).Value = "Country"
xlsWorkSheet.Cells(1, 4).Value = "Profession"
xlsWorkSheet.Cells(1, 5).Value = "Phone"
xlsWorkSheet.Cells(1, 1).Font.Bold = True
xlsWorkSheet.Cells(1, 2).Font.Bold = True
xlsWorkSheet.Cells(1, 3).Font.Bold = True
xlsWorkSheet.Cells(1, 4).Font.Bold = True
xlsWorkSheet.Cells(1, 5).Font.Bold = True
I = 1
Open App.Path & "\Phones.txt" For Input As #1
Do While Not EOF(1)
Line Input #1, NewLine
I = I + 1
AA = Split(NewLine, delim)
For Z = LBound(AA) To UBound(AA)
xlsWorkSheet.Cells(I, Z + 1).Value = Replace(AA(Z), DD, "")
Next Z
Loop
Close #1
xlsWorkSheet.Columns.AutoFit
xlsWorkSheet.Cells(1, 1).Interior.ColorIndex = 20
xlsWorkSheet.Cells(1, 2).Interior.ColorIndex = 20
xlsWorkSheet.Cells(1, 3).Interior.ColorIndex = 20
xlsWorkSheet.Cells(1, 4).Interior.ColorIndex = 20
xlsWorkSheet.Cells(1, 5).Interior.ColorIndex = 20
xlsWorkSheet.Name = "Phones"
xlsWorkSheet.SaveAs App.Path & "\Phones.xls"
xlApp.Quit
Set xlsWorkSheet = Nothing
Set xlsWorkBook = Nothing
Set xlApp = Nothing
Me.MousePointer = 0
ReturnCode = ShellExecute(hwnd, "Open", App.Path & _
"\Phones.xls", "", App.Path, 1)
End Sub

Private Sub Form_Load()
Command1.Caption = "Import To Excel"
End Sub

Sunday, November 11, 2007

Make Money Online with PayPerPost

Have you ever heard of PayPerPost? If you don't, you're "leaving money on the table", as some internet guru says. Read on.

PayPerPost or PPP is a website which helps content creators such as bloggers, videographers, podcasters and photographers find advertisers willing to sponsor specific content. The advertisers create opportunities that describe the content they are looking for (e.g. feedback, reviews, buzz, creative, video). The bloggers, or "Posties" as sometimes called, then choose opportunities in their area of interest.

Once the blogger has written a blog post or posted a video that matches the requirements, PayPerPost then reviews the post against its requirements and their terms of service and handles payment to the blogger once it passed.


Personal Experience
If you are skeptical about this, don't be. My very first PayPerPost post earned me twenty (20) dollars. Since then I earned another thirty (30) dollars. If you're asking why I have low earnings, it's because this blog has low PageRank - 2 as of this writing. If your blog has a high PageRank, you have a higher chance to qualify for more opportunities with higher pay to blog about and you get more earnings.

A Word of Advise
Some of your readers may not be please seeing some sponsored post (post sponsored by PayPerPost) in your blog. So it's wise not to do it everyday. My technique when I write sponsored post, I make it to a point that it is the first post I made on that day and then I post again immediately so that it is not my most recent post. This way, it is not as noticeable as it is when it's on the topmost position in you blog.

Where To Go From Here
If you have a blog, this is another source of income for you, on top of serving ads. If you have been blogging about anything but not getting paid, this is your chance to get paid. Sign-up to PayPerPost, submit your blog for approval and then get paid while blogging.

Friday, November 09, 2007

Website Content Mistakes

When building a website, you definitely have to have good contents for visitor of your site. And it's not just contents, it's got to be 'good information' for them to come back for more. Let's face it, search engines love website with good content, especially if it is updated regularly, and web surfers hungry for information. If your website caters the needs of this two, you got thousand hits a day and a potential gold mine.

Building good contents for your site is not automatic, especially if you're a beginner and a struggling writer. Consider this few pointers on how you can avoid some website content mistakes.

1. Don't have a site built purely from your own content.

Why? Because it will take too long to grow lots of pages. Although unique, quality content is the bees knees if you ignore other sources of content you are, to quote the cheese-gurus, 'leaving money on the table'.

2. Don't have a site built purely from other people's content

Why? Because you'll have little that's unique on your site. Every man and his dog tries to borrow other people's content and use content that already exists elsewhere.
But that doesn't make it right: "If you do what everybody else does, you'll get what everybody else gets."

Search engines can frown on duplicate content so if you use sources of content that are not unique you'll need to do things to make those pages unique. But the best plan is not build a site entirely from other people's content

3. Don't have a site built purely of 'synthesized' content

Why? Because using fancy article-crawling-machines and other 'automatic content machines' will backfire on you eventually. It might make you some revenue in the short-term but it's like trying to build a house with bricks but no mortar. Sure - it's WAY quicker, but I know which house I'd rather live in and which one is still going to be there in a year's time.

Thursday, November 08, 2007

How to Add Links to Your Blog Labels

Labels or tags, as popularly known, are words or phrases that you put in your blog post to group related posts.

Adding labels is a great way to organize your blog posts into categories or topics. It help your readers to navigate easily through your blog (or website) just by clicking on a particular label. Without it, reader will have to go to your archives to read your post from previous months. Such a waste of time if he/she have to scan monthly archives when he/she is only interested in your posts that talk about making money online.

This Blog's Labels


In the new Blogger, adding label is very simple if you use a non-customized template provided by Blogger. But if you choose to customize it, you have to manually add links your post labels. Here's how.

Copy all the your blog label's URL from your browser's address bar. You can display the label's URL by clicking on it. Gather all that URL and then put each in <a> and <li> tag. See a live example below using this blog's labels.

<h2 class="sidebar-title">Categories</h2> 
<ul>
<li><a href="http://joelbadinas.com/search/label/adsense">Adsense</a></li>
<li><a href="http://joelbadinas.com/search/label/bloggers%20corner">Blogger's Corner</a></li>
<li><a href="http://joelbadinas.com/search/label/blogging">Blogging Tips</a></li>
<li><a href="http://joelbadinas.com/search/label/everyday%20life">Everyday Life</a></li>
<li><a href="http://joelbadinas.com/search/label/java">Java</a></li>
<li><a href="http://joelbadinas.com/search/label/make%20money%20online">Make Money Online</a></li>
<li><a href="http://joelbadinas.com/search/label/oracle">Oracle</a></li>
<li><a href="http://joelbadinas.com/search/label/php">PHP</a></li>
<li><a href="http://joelbadinas.com/search/label/programming">Programming</a></li>
<li><a href="http://joelbadinas.com/search/label/ramblings">Ramblings</a></li>
<li><a href="http://joelbadinas.com/search/label/seo">SEO</a></li>
<li><a href="http://joelbadinas.com/search/label/traffic%20generation">Traffic Generation</a></li>
<li><a href="http://joelbadinas.com/search/label/vb6">Visual Basic</a></li>
<li><a href="http://joelbadinas.com/search/label/web%20hosting">Web Hosting</a></li>
</ul>


Now, open your template and paste it in the sidebar (or anywhere you want), preferably just under the About Me section.

Tuesday, November 06, 2007

How to Write to an INI File in Visual Basic

INI files are useful when you want to store the latest state of your program.

In my own experience, I use INI files to read and write any information such as the last user who logs in the system and some initialization of my programs that is not possible through databases.

One thing I like about INI files is that you can change the state or behavior of your program without recompiling it. Since INI files are just text file, you edit it using notepad or any word processing softwares.

If you want to know how to read from an INI file, see my how to read from an Ini file post.

This sourcecodes is also written in Visual Basic 6.

'Procedure: WriteSettingToIni
'Language: Visual Basic
'Parameter: Filename As String = the filename and path of the ini file
' Section As String = a section in an ini file
' Key As String = a key in an ini file that contains the value to read
' Value = the value to write
'Purpose: Writes a value to an INI File
'Usage: WriteSettingToIni("c:\test.ini", "User", "Latest", "kabalweg")


'-->API DECLARATION
Public Declare Function WritePrivateProfileString Lib _
"kernel32" Alias "WritePrivateProfileStringA" _
(ByVal lpApplicationName As String, ByVal lpKeyName As Any, _
ByVal lpString As Any, ByVal lpFileName As String) As Long


'-->WRITE TO AN INI FILE
Public Sub WriteSettingToIni(ByVal Filename As String, _
ByVal Section As String, _
ByVal Key As String, _
ByVal Value As String)
Call WritePrivateProfileString(Section, Key, Value, Filename)
End Sub

Monday, November 05, 2007

How Edit Your Template in the New Blogger

Are you having trouble where to go to edit your template in the new Blogger? Don't be upset, you're not the only one. I was in the same situation you're in until I discovered it's just two clicks away.

Just days after I was first introduced into blogging, I started editing templates. But when the new version of Blogger was introduced, I was lost. I always "Revert to Classic Template", when editing my blog's template, when in fact I don't have to. Here's how to.

In your new Blogger blog Dashboard, click the "Layout" link to display the "Template" tab. Now click the "Edit HTML" link. (See picture below)



After you click the "Edit HTML" link, under the "Edit Template" section, click the "Expand Widget Templates" checkbox to expand you template. (See picture below). By now you can see the complete sourcecodes of your templates. You can now edit it.



If "Expand Widget Templates" checkbox is uncheck, you will only see your blog template's wrappers. If checked, Blogger will show the complete template's sourcecodes.

Of course, you don't have to get your hands dirty with sourcecodes, you can use the "Page Element" section, under "Template" tab, to add page elements to you blog. But if you're like me who wants to have complete control in my template, this could help. (^_^)

Remember to backup your template before you attempt to edit it. It pays to be sure.

Sunday, November 04, 2007

How to Read from an INI File in Visual Basic

INI files are useful when you want to store the latest state of your program.

In my own experience, I use INI files to read and write any information such as the last user who logs in the system and some initialization of my programs that is not possible through databases.

One thing I like about INI files is that you can change the state or behavior of your program without recompiling it. Since INI files are just text file, you edit it using notepad or any word processing softwares.

Below is a read to use function that you can use to read from an INI files. It is written in Visual Basic 6.

Procedure: ReadSettingFromIni
Language: Visual Basic 6
Parameter: Filename = the filename and path of the ini file
Section = a section in an ini file
Key = a key in an ini file that contains the value to read
Purpose: Read a value from an ini file through an API
Usage: MsgBox ReadSettingFromIni("c:\test.ini", "User", "Latest")


'-->API Declaration
Public Declare Function GetPrivateProfileString Lib _
"kernel32" Alias "GetPrivateProfileStringA" _
(ByVal lpApplicationName As String, ByVal lpKeyName As Any, _
ByVal lpDefault As String, ByVal lpReturnedString As String, _
ByVal nSize As Long, ByVal lpFileName As String) As Long


Public Function ReadSettingFromIni(ByVal Filename As String, _
ByVal Section As String, _
ByVal Key As String) As String
Dim ret As String * 255
Dim NC As Long

NC = GetPrivateProfileString(Section, Key, "", ret, 255, Filename)
If NC <> 0 Then ReadSettingFromIni = Left$(ret, NC)
End Function

Enjoy...

Saturday, November 03, 2007

My Gadget in the iGoogle Gadget Directory

My Free Online Recipe gadget is now listed in the iGoogle Gadget Directory. I've been waiting for this gadget to be listed since I submitted it on 26th of October. Now that it's listed, iGoogle users can now see it when searching using the following search phrases, 'free online recipes', 'free recipes' and 'recipes' in the gadget directory. Although it's not in the top results of those phrases, I expect to move it slowly if it gain more users.

How To Add Social Bookmark Links In Blogger

If you want some needed traffic, social bookmark sites can give you that. It can give your blogs sudden rush of traffic specially if the topic you submitted is informative. In my own experience, whenever I submit a good topic to just even one social bookmarking site, it gives me 100 to 300 more visitors to my website. Submit a topic to many social bookmarking sites and you can do the math.

But take note that this traffic is not permanent. And if visitors notice that your content is rubbish, they may feel they have been tricked and will leave at once and may never come back. So make sure that you only submit your good contents.

Social Bookmark Links

In this blog, I'm using http://technorati.com, https://secure.del.icio.us, http://digg.com, http://www.propeller.com, and http://www.stumbleupon.com bookmarking sites.

Social Bookmark Sourcecodes

See the social bookmark sourcecodes below:

<div class="post-body">
Bookmark via
<a href="http://technorati.com/faves?add=<$BlogItemPermalinkURL$>&title=<$BlogItemTitle$>">Technorati</a> |
<a href="http://del.icio.us/post?url=<$BlogItemPermalinkURL$>&title=<$BlogItemTitle$>">del.icio.us</a> |
<a href="http://digg.com/submit?phase=2&url=<$BlogItemPermalinkURL$>&title=<$BlogItemTitle$>">Digg it</a> |
<a href="http://www.propeller.com/submit/?U=<$BlogItemPermalinkURL$>&T=<$BlogItemTitle$>">Netscape</a> |
<a href="http://www.stumbleupon.com/submit?url=<$BlogItemPermalinkURL$>&title=<$BlogItemTitle$>">StumbleUpon</a>
</div>

Open you Blogger blog's template. Copy the the sourcecodes above and paste it in your template right after the the <div> tag that contents the <$BlogItemBody$> tag.

<div class="post-body">
<p>
<$BlogItemBody$>
</p>
</div>

(PASTE SOCIAL BOOKMARK SOURCECODES HERE)

There you have it, add the social bookmark links, submit your good content to social bookmark sites by clicking on the links and expect a sudden rush of traffic. A word of caution, do not overuse it or else you might get banned from this sites.

Thursday, November 01, 2007

How To Get the Address Bar URL in PHP

If you want to get the full URL in your browser's address bar, this PHP function can help you. One practical use is when you want to add a social bookmark section in you site so that you can automatically submit the current webpage.

In Blogger who don't have the same problem because you have the
<$BlogItemPermalinkURL$> tag that returns the post's URL.

Here's the PHP sourcecodes:

function getOwnURL() 
{
$s = empty($_SERVER["HTTPS"]) ? '' : ($_SERVER["HTTPS"] == "on") ? "s" : "";
$protocol = strleft(strtolower($_SERVER["SERVER_PROTOCOL"]), "/").$s;
$port = ($_SERVER["SERVER_PORT"] == "80") ? "" : (":".$_SERVER["SERVER_PORT"]);
return $protocol."://".$_SERVER['SERVER_NAME'].$port.$_SERVER['REQUEST_URI'];
}

function strleft($s1, $s2)
{
return substr($s1, 0, strpos($s1, $s2));
}

To use, just invoke the function within the PHP print method like this:

print(getOwnURL()); 

Wednesday, October 31, 2007

Waiting for Adsense Payment

Yesterday, my Adsense earning have passed the 100 dollar mark (today it's $103.24). This means that it will be days from now and I will have my third Adsense check. Good thing that I can now get your earnings through Western Union. It's much faster than the regular mailed check.

Looking back at my previous Adsense earnings, it took me eight months before I received my first check and six months after that my second check. This third 100 dollar mark only took me three months to surpassed. This means that my earning is improving. Although my goal to make 10 dollars per day this year is slowly slipping, I still have two months to do it. Who knows next year I might get lucky.

My regular earner is a blog (not this one) and a website. I will not enumerate those two regular earners this time, maybe next.

Tuesday, October 30, 2007

Western Union Adsense Payout

Good news to Adsense publishers. You can now utilize the ease of Western Union Quick cash system.

Adsense publisher can now receive their Adsense revenue through Western Union. This service is only available, as of this writing, to publishers from the following countries: Argentina, Chile, China (Mainland), Colombia, Malaysia, Pakistan, Peru, the Philippines, and Romania. I'm sure they will broaden the country coverage in the days to come.

To receive your earnings by Western Union Quick Cash, here are the steps:

1. Sign in to your account at www.google.com/adsense.
2. Visit the My Account tab.
3. Click the ‘edit’ link adjacent to the ‘Payment Details’ header.
4. Select the Western Union Quick Cash radio button.
5. Click ‘Continue’.
6. Click ‘Save Changes’ to save your payment type.

Just make sure that the name on your account exactly matches that on the government issued ID card that you will bring to pick up your Western Union Quick Cash payments.

Monday, October 29, 2007

Stay Hungry. Stay Foolish.

This is one of the best inspirational text I've ever read. It makes me think of my current job. Is it well enough for me? I am happy with where I am now? Should I stay with the company?

The text I am referring to is the Commencement Address of Steve Job to graduates in a university in 2005. It made a big impact in me specially so that Steve Job is in the IT industry also (I'm a computer programmer and he's one of the founder of Apple).

I recommend reading this to everyone. Here the link: 'You've got to find what you love,' Jobs says.

Sunday, October 28, 2007

Disclosure Policy

This policy is valid from 29 October 2007

This blog is a personal blog written and edited by me. This blog accepts forms of cash advertising, sponsorship, paid insertions or other forms of compensation.

The compensation received will never influence the content, topics or posts made in this blog. All advertising is in the form of advertisements generated by a third party ad network. Those advertisements will be identified as paid advertisements.

The owner(s) of this blog is compensated to provide opinion on products, services, websites and various other topics. Even though the owner(s) of this blog receives compensation for our posts or advertisements, I always give my honest opinions, findings, beliefs, or experiences on those topics or products. The views and opinions expressed on this blog are purely mine. Any product claim, statistic, quote or other representation about a product or service should be verified with the manufacturer, provider or party in question.

This blog does contain content which might present a conflict of interest. This content may not will always be identified.

My PageRank Increased

Today I visited two of my blogs, this blog and my funny jokes and amusing stories, and noticed something very much significant for a website. My PageRank increased. This blog goes from 0 to 2 pagerank, while my funny jokes and amusing stories blog went to 4 from a long time 3.

For many who don't know, PageRank is very important for a website if you are just relying in the search engine, like Google, Yahho, MSN and etc., for you website's traffic source. It helps you get high rank in the SERP (Search Engine Result Page) - it's the results when you search for something in search engines.

Imagine if your website is always in the number #1 spot of a highly search word or phrases (ie: 'recipe') in search engines, you will get literally thousands or even millions of visitors per day. Which means, more visitors, more money in advertising revenue.

Saturday, October 27, 2007

Free Online Recipe Gadget

Yesterday, I uploaded my very first Google gadget, the Free Online Recipe gadget. Google Gadgets are mini-applications that work with iGoogle, Google Desktop, or any page on the web. They can range from simple HTML to complex applications, and can be a calendar, a weather globe, a media player, or anything else you can dream up.You can go to this link to know more about it.

My gadget displays free recipes from my Free Online Recipe Collections website. You can add this gadget to your websites or blogs, and best of all, you can customize it's appearance to fit your website's or blog's theme.


Screenshot

You can get the Free Online Recipe gadget below:
1) For blogs or website click here.
2) For iGoogle click here.

Tuesday, October 23, 2007

Should You Quit Your Job?

Should you quit your job? Maybe this simple test can help you decide. (^_^)

Here's my result, what's yours?

Your Job Dissatisfaction Level is 39%

Your job is not bad, but it's probably not a long term thing.
You're just not happy enough to stick around for too long...
And there's little that can change how you feel.
Start looking around for other options, but only quit for something really good!

How To Connect To A Database In Java

This source codes, written in Java, demonstrates how to connect to a database using JDBC and ODBC. The source codes is well commented for you to follow easily.

import java.sql.*;

public class jdbcConnect {
//CLASS CONSTRUCTOR
public jdbcConnect() {
}

//THIS PROC WILL SET THE CONNECTION TO THE DATABASE,
//QUERY AND PRINT THE RESULT TO THE STANDARD OUTPUT
private void loadData()
{
Connection con = null;
Statement stmt = null;
ResultSet rst = null;

//SET ERROR TRAP FOR CONNECTION TO THE DATABASE
try
{
//FOR ODBC CONNECTION
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver").newInstance();
//dsn_employee = data source name(dsn)
//un = username
//pw = password
con = DriverManager.getConnection("jdbc:odbc:dsn_employee;
UID=un;PWD=pw");

//CHECK IF THE CONNECTION TO THE DATABASE IS SUCCESSFUL
if(!con.isClosed())
{
//MAKE THE ACTUAL CONNECTION TO THE DATABASE
stmt = con.createStatement(rst.TYPE_SCROLL_SENSITIVE,
rst.CONCUR_READ_ONLY);
//EXECUTE THE SQL QUERY
rst = stmt.executeQuery("SELECT fullname FROM employee");

//CHECK IF CURRENT ROW IS THE LAST
while(!rst.isLast())
{
//SET THE ERROR TRAP FOR READING THE RECORDSET
try
{
//GO TO THE NEXT RECORD OF THE RECORDSET
rst.next();
//PRINT THE RECORD TO THE STANDARD OUTPUT
System.out.println(rst.getInt("fullname"));
}
//HANDLE TRAPPED ERROR ON READING THE RECORDSET
catch(Exception e)
{
//PRINT THE ERROR MESSAGE
System.out.println("ERROR: " + e.getMessage());
}
}
}
}
//HANDLE TRAPPED ERROR ON DATABASE CONNECTION
catch(Exception e)
{
//PRINT THE ERROR MESSAGE
System.err.println("ERROR: " + e.getMessage());
}
finally
{
try
{
if(con != null)
{
//CLOSE THE CONNECTION
con.close();
}
}
catch(SQLException e)
{
//PRINT THE ERROR MESSAGE
System.out.println("ERROR: " + e.getMessage());
}
}
}

//START OF PROGRAM
public static void main(String[] args) {
jdbcConnect dbConnect = new jdbcConnect();
dbConnect.loadData();
}
}

Monday, October 22, 2007

How to Connect to an Oracle Database in Visual Basic

This is ready to use function written in Visual Basic 6. This function will connect to an oracle database. See the sourcecodes below.

'Procedure: ConnectOracle
'Language: Visual Basic 6
'Parameter: strUN = username,
' strPW = password,
' strHost = host string
'Purpose: This procedure will connect to a Oracle database
'Usage: Call ConnectOracle("scott", "tiger", "oradb")

Public Sub ConnectOracle(strUN As String, _
strPW As String, _
strHost As String)
Dim Conn = New ADODB.Connection
Conn.Open "Provider=OraOLEDB.Oracle.1;" & _
"Persist Security Info=False;" & _
"User ID='" & strUN & "';" & _
"Data Source='" & strHost & "';" & _
"Password= '" & strPW & "'"
End Sub

Tuesday, October 16, 2007

No Right-Click Script

Forget long Javascript codes that disables the right-click or the context menu in your webspage. Here's a simple script that you can use to disable the right-click or the context menu in you website.

oncontextmenu="return false;

Add the Javascript codes above in the opening <body> tag of your webpage. See the example below.

<body oncontextmenu="return false;">
Put you contents here...
</body>

Take note that some browser ignores it. An example is the Opera browser, which ignores all of the no right click scripts including the no right-click script above. Likewise, it will not prevent the user from seeing your webpage's sourcecodes by using the View>Page Source or View>Source menu.

My advise is to test the script with your target users browser or with major browser around.

Wednesday, October 10, 2007

Pinoy Transformers

Move away Captain Barbel and Darna, here comes the new breed of Pinoy heroes. The Pinoy Transformers.


Monday, October 08, 2007

How Change Your Website's Shortcut Icon

One way to personalize you website is change it's shortcut icon. And doing it is very easy. All you have to do is put the following HTML code in the <HEAD> section of every page of your website:

<link rel="shortcut icon" href="http://img.cooks.com/favicon.ico" />


Just change the <b>href</b> attribute value with the URL of the icon you intend to use. See the complete example below:

<html>
<head>
<title>Shortcut Icon</title>
<link rel="shortcut icon" href="http://img.cooks.com/favicon.ico" />
</head>
<body>
Put body text here...
</body>
</html>

Will To Win: Pacqiuao Upsets Barrera

Yesterday, the Philippines literally stopped to watch Will To Win: Pacqiuao vs Barrera 2. I was one of them (^_^).

Pacquiao upsets Barrera in the fight which lasted 12 rounds via a unanimous decision. Although I was a little bit disappointed because I was expecting a knockout that didn't happen, still I was happy that Pacquiao won the fight. One more Mexican left to demolish, Juan Manuel Marques. I hope Pacquiao finishes him like what he did to Morales and Barrera. (^_^)

During the Fight
Post Fight

Friday, October 05, 2007

Will To Win: Pacqiuao vs Barrera 2


Pacquiao versus Barrera 2 will be aired tomorrow on GMA tv. I'm already excited. I miss seeing Pacquiao fighting. It has been months since I his last fight and I'm sure I share this feelings to all Filipinos and boxing fans around the world.

Tomorrow, Filipinos will unite again. They'll be less traffic congestions and low crime rate. The Philippines will come to a halt literally. Since I'm alone at home, no one will urge me to change the channel. The last fight of Pacquiao (Pacquiao and Morales III), I was really pissed off because my sister and niece told me ahead that Pacquiao won the match. Now, I'll be cautious. No cellphone, no telephone and no changing of channel. (^_^)


















Manny Pacquiao | WBC Int'l Super Featherweight Champion | W 44 (35 ko's)  |  L 3  |  D 2  | Total 48 Marco Antonio Barrera | Former WBC Featherweight Champion | W 63 (42 ko's) | L 5 | D 0 | Total 68
Sex:MaleMale
Nationality:FilipinoMexican
Alias:PacManBaby Faced Assassin
Birth Name:Emmanuel D. PacquiaoMarco Antonio Barrera Tapia
Hometown:General Santos City, PhilippinesGuadalajara, JA, Mexico
Birthplace:Bukidnon, PhilippinesMexico City, DIF, Mexico
Rated at:Super FeatherweightSuper featherweight
World Rank:1 / 9473 / 947
Date of Birth: 1978-12-171974-01-17
Age:2833
Reach:67"70"
Stance:SouthpawOrthodox
Height:5'6"½5'6"


Weigh in

Monday, October 01, 2007

Unwinding in the Paradise Island

Yesterday, three of my officemates and I went to Paradise Island, one of many beach in the Island Garden City of Samal (IGACOS), to unwind and get away from the busy city of Davao.

We departed at six in the morning and went back home at around one in the afternoon. It was my second time in the place. The resort was nice, clean seawater, white sand and good amenities.

Going to Paradise
Food for Brunch
Beach Area
Boarding for Home
On the Boat to Home
On the Car to Home

More pictures here

Recent Post