Penasaran dapat link ini (mesti dibaca full supaya bisa mengklik linknya):
Gentoo Forums :: View topic - Some ext3 Filesystem Tips
Ternyata, luar biasa :D, beberapa saja yang saya praktekkan karena masih ada was-was :D. Reboot, trus boot make Damn Small Linux trus lakukan perubahan… Setelah itu lakukan “tuning” lagi lewat link ini:
HOWTO: Set up Edgy for [...]

»

HOWTO: Create Autocomplete on your CCK field or other field on Drupal

Posted on: November 21, 2008 | comment (0)
Tags: , ,

It’s amazing to play with Drupal. You can alter “almost” anything on the code without changing into core module directly. All you can do is create custom module then using Drupal hook API, you can alter the function, theme or whatever it is.

One most powerful hook is hook_form_alter. You can change form element using this function. For this how to, we try to change behavior one or more field with auto complete feature. Auto complete feature is an AJAX routine which fetch some data and display them as a option list. You can use this for search users, city, tags or whatever you want.

Ok, let’s start.

The code is taken from user.module and we modified it to fit our needs. First, you have to create a module, let say mymodule.module save it into sites/all/modules/mymodule directory. Don’t forget to add mymodule.info file on that directory :)

Copy and paste code as follows:

function mymodule_menu($may_cache) {
$items = array();
$items[] = array(
‘path’ => ‘data/autocomplete’,
‘title’ => t(’Data autocomplete’),
‘callback’ => ‘data_autocomplete’,
‘access’ => user_access(’access content’),
‘#default_value’ => $node->name ? $node->name : ”,
‘type’ => MENU_CALLBACK
);
}

function mymodule_form_alter ($form_id, &$form) {
if ($form['form_id']['#value'] == ‘best_practice_node_form’) {
$form['field_related_data_tag'][0]['value']['#autocomplete_path'] = ‘data/autocomplete’;
}
}

From sample above, I created a CCK field with named related_data_tag, I add autocomplete feature for this field by alter it with form_alter hook. The autocomplete path refers to link data/autocomplete. So we have to create menu data/autocomplete too. This menu will hook data_autocomplete function as follows:

function data_autocomplete($string = '') {
$matches = array();
if ($string) {
$result = db_query_range("SELECT title FROM {node} WHERE LOWER(title) LIKE LOWER('%s%%')", $string, 0, 5);
while ($data = db_fetch_object($result)) {
$matches[$data->title] = check_plain($data->title);
}
}
print drupal_to_js($matches);
exit();
}

Add this function below mymodule_form_alter function. This function will search node title and display as autocomplete list. Try it and if you have difficulties, feel free to ask me :)

Case Study: How To Setup Multisite Configuration on Drupal

Posted on: April 20, 2008 | comment (1)
Tags: ,

One of the feature of Drupal Content Management Framework, you can set multi site with a single code base without a massive modification on scripts code. We just set up some configurations on Apache Web Server (I assume you use this great web server software) and some configuration on Drupal settings (yes, Drupal has provided this multisite configuration out of the box).

If you unpacked the Drupal package, you may find on settings.php comment how to set up multisite. From my experience, I have read many posts but I have to tear my hair off to get it done. From this documentation, it makes sense, and I want to start from there.

Okey, I have case study to share with you. I have set up multisite with different subfolder. Yes, you may apply this for subdomain too. First I will describe how to set up multisite with sub folder: http://playwithbeauty-id.com/magicspell, and http://playwithbeauty-id.com/whiteglam.

You have to have some knowledge about:

  1. Edit Apache configuration and reload the web server
  2. Edit Drupal configuration ;). I bet you know this one.

First we edit apache configuration. Configuration path depends on your installation and operating system, find httpd.conf or apache.conf then add this line:

Alias /magicspell /PATH_TO_YOUR_PUBLIC_HTML/
Alias /whiteglam /PATH_TO_YOUR_PUBLIC_HTML/

You may change magicspell and whiteglam with your own sub folder. The second step is create multisite folder on Drupal root folder:

mkdir -p sites/playwithbeauty-id.com.magicspell/{files,themes}
mkdir -p sites/playwithbeauty-id.com.whiteglam/{files,themes}

Commands above create two multisite with files and themes folder. We create separate files and themes folder to make a different theme with the main site. Now copy settings.php file from the default configuration to those folders:

cp sites/default/settings.php sites/playwithbeauty-id.com.magicspell/
cp sites/default/settings.php sites/playwithbeauty-id.com.whiteglam/

Edit those settings.php with different database configuration to make them properly separated. Also you can set $base_url variable to reflect the website URL (recommended).

Okey, reload the apache configuration:

apachectl graceful

Then try to access those subfolder URL. If you find an installation page, then you are done! Follow the instruction and create a custom theme for your new subfolder by copying your theme on sites/YOUR_DOMAIN.subfolder/themes. Good Luck!

Wordpress 2.5 review, an UI comparison with Drupal

Posted on: April 1, 2008 | comment (1)
Tags: ,

One word to describe this release: “excellent”. I love the User Interface (UI) administration theme, the tone color, layout and a touch of AJAX on some functions, for example editing permalink.

The UI design is almost similar with Drupal style: some item can be collapsed or expanded to save some rooms. So when using this release, my behaviour is similar when using Drupal website.

I hope the Drupal developers can use this new Wordpress UI design for Drupal administration theme. I know that we can define one theme for administration theme on 5.x releases. I found version 6.x did too but I wish Drupal will create a dedicated theme special for administration section like Wordpress or Joomla did.

The similar administration theme for every release will help people to get used to use the UI. What about Drupal version 7.x?

Drupal 6.0 released

Posted on: February 19, 2008 | comment (0)
Tags:

I’m visiting drupal.org and find that Drupal 6 has released. I can’t wait to test this released but I will wait until all bugs, fixes and some improvement made into the next minor version, maybe 6.1, 6.2 etc.

Some projects that I have done using this fabulous content management system. Some features and improvements that I love most are:

  1. Actions and triggers: We can define an action or trigger for when we create/modified the post.
  2. CSS-only theming: wow, this is wonderful. We can control the theming only with CSS without writing a line of PHP code!
  3. Performance and maintenance improvement such better file handling and new menu system
  4. Add much more…

The server infrastruture and additional components to build a website

Posted on: February 14, 2008 | comment (0)
Tags: , , ,

Many of my clients ask some specifications about server infrastructure, what operating system they use, where we host the website, web applications to build the website, etc. Here are some brief explanations about server infrastructure and additional component to build the website.

Operating system

We use Linux operating system. Linux is a robust, secure and reliable operating server especially for servers. It is widely used as server on the datacenter or intranet. The combination of apache as web server, MySQL or PostgreSQL as database server and PHP as scripting language make this operating system is popular as the server infrastructure.

Based on netcraft.net (http://www.netcraft.net) survey, apache http server get 50.61% market share on the internet. MySQL is widely used as database server, it¡¦s fast robust and reliable as database server on the internet. Even Google use modified MySQL as their database servers.

PHP is no doubt as the most popular scripting language to build web applications. It is fast and easy to learn.

Web Hosting

Hosting is available on local server (Indonesia) or on USA.

The advantage and drawbacks

Item Local server USA
Access speed Faster access from local market but so slow accessed from outside Indonesia Moderate access from local market and faster access from outside Indonesia.
Stability 99% stable and 99.5% uptime uptime. Downtime occurs only by electricity failure 99.9% stable and 99.9% uptime
Security Moderate. Depends on operating system and firewall setup Mostly monitored and hardened with additional fees.
Backup Good backup but need additional fees for external backup to ensure data is safe if hard drive server is crashed Good backup but need additional fees for external backup to ensure data is safe if hard drive server is crashed
Support Good support from datacenter and we can go there directly to fix things Good support but can not go there directly to fix things

Note: uptime is calculated by how many times server up or online in one year.

Content Management System

Popular content management system are:

  1. Drupal, the most extensible, robust and secure content management system. Drupal is designed for community websites, web 2.0 enabled website, company website even for personal use. It can be extended by modules for various needs.
  2. Wordpress, the most popular content management system. This is the widely used by personal for blogging because its functions as blogging tool. Wordpress can be used as company websites or another needs. It can be extended by plugins.