Thursday, July 14, 2011

How to Determine The Visitor's City, State, Province & Country Automatically with Javascript using Google APIs - Get your Visitors Location with Javascript

If you need to get your visitor's city, state, province & country using javascript, you can do that by using Google APIs. Its very easy to do with a few lines of code and can provide a lot of possibilities because you can determine your visitors location with javascript. You can set your site's language, timezone, or design according to your visitors location. Here are the instructions:

Saturday, May 28, 2011

How To Fix SmartBro Slow Internet Connection & Get 2 Mbps Speed

SmartBro gave me some problems with their customer support the past week regarding my slow SmartBro internet connection (I detailed it in my previous entry). Here are the instructions of the things I did to get 2 Mbps with my SmartBro plan 999 canopy-type connection:

Thursday, May 26, 2011

My Slow SmartBro Internet Connection (And How To Fix It)

Let me warn you now that this will be a long post, since I wanted to detail out my experience with Smart Bro customer support and their lack of experience in handling my situation.
Update: Here's my post on the steps I did to achieve 2Mbps speed: How To Fix SmartBro Slow Internet Connection & Get 2 Mbps Speed
About a week ago, our SmartBro canopy antenna fell down from its installation because of the strong winds. I immediately called up their hotline *1888 (on my Smart number) and told them the scenario. The rep told me they will be scheduling the deployment asap. Luckily, their installation team (the rep pertains to them as the "contractors") arrived at our home the next day.

Wednesday, February 09, 2011

JQuery: How To Get URL Parameters & Values

While developing on a Drupal website, I was using the URLFill module to automatically fill in the form fields with some GET variables in the URL (something like http://example.com?var1=value1&var2=value2). For some reason it is not filling-up a Content Taxonomy field where the widget is set as autocomplete. So what I did was to implement the auto-filling of the said field with JQuery. This was the function I used:

Saturday, January 29, 2011

15 Sites Web Developers and Designers Should Know

Creating a good website isn’t an easy task, but there’s a few tools that can definitely make your developer or designer life easier. In this article, I have compiled 15 extremely useful website that any web developer or web designer should have bookmarked.

Monday, January 17, 2011

Drupal 6: Embedding a View in a Template using views_embed_view

If you need to embed a view inside a template or a node if the input type is PHP code, there is a very simple function called views_embed_view() which will allow you to do so very easily.



I posted another method of doing this before here but this one is much simpler. The views_embed_view has 2 default arguments. The second argument allows you to enter the display_id of the view (example: default, page, block, etc). Any additional argument you specify will be passed to the views argument handler. For instance, if you wanted to embed the block view and pass it a list of nodeIDs as an argument:


<?php
$viewName = 'MYVIEWNAME';
$display_id = 'block';
$myNodes = array(1, 2, 3);
print views_embed_view($viewName, $display_id, $myNodes);
?>


Source: http://thedrupalblog.com/embedding-view-drupal-6-using-views-embed-view

Friday, December 10, 2010

Windows: 8 Desktop and Window Management Shortcuts

If you are serious about productivity, one of the best "upgrades" you can pull up in your computer knowledge arsenal is learning a few nifty Windows shortcuts to manage your desktop and the arrangement of your windows. Here are 8 Windows shortcuts that uses the Win key to organize the open program windows on your desktop:

Drupal: Add a Command-line Interface with the Drush Module

The Drush module for Drupal allows you to have a command-line interface and a scripting environment for your Drupal website if you are accustomed to using the command prompt (mostly available to dedicated and virtual private servers). drush means Drupal Shell.

Tuesday, November 30, 2010

PHP: How to Scrape Websites using Simple HTML DOM Parser

Scraping websites or Web scraping is a method of collecting data off from websites using a program to automate the process. Wikipedia defines it as "a computer software technique of extracting information from websites." For whatever purpose it may be, the creation of web scraping PHP scripts has been made easier using this PHP class for parsing HTML content. From the PHP Simple HTML DOM Parser website:

  • A HTML DOM parser written in PHP5+ let you manipulate HTML in a very easy way!

  • Require PHP 5+.

  • Supports invalid HTML.

  • Find tags on an HTML page with selectors just like jQuery.

  • Extract contents from HTML in a single line.



I have used this class several times already in some of my projects and it does work well. Below are some sample codes:

Monday, November 15, 2010

Drupal: Easy Themeing with Fusion

The more I'm using Drupal, the better I understand why a lot of developers choose it as a top choice when it comes to creating community-driven websites. And another great tool at our dispense for creating Drupal sites is the Fusion theme.