Navigation

Blog Category

Archive Blogs

August 2010
SunMonTueWedThuFriSat
1234567
891011121314
15161718192021
22232425262728
2930311234

Blogs

Views AJAX exposed filter wthout pressing apply

Views 2 has an option to have exposed filters update the view using AJAX. but the AJAX update is triggered only once the "Apply" button is pressed. If you want the AJAX update to happen automatically as soon the filters are changed you can add your own behavior in your own module to hide the apply button and trigger its submit on change of all filter fields as shown below.

  1. Drupal.behaviors.modulename = function (context) {
  2.   $("form#views-exposed-form-viewname-page-1 #edit-submit").hide();

Strange white space in html when using custom TPL in Drupal

Recently we encountered a strange issue.
We had some custom templates for drupal views.
Some extra white space was coming just before the content of the TPL was starting.
Usually white space is ignored in HTML, but for some strange reason this white space was not ignored in IE7 , and was causing the design issue.

When we removed the custom TPL files the white space was disappearing.

Even if we put the default TPL code in the custom file, the issue was still there.

Migrating Image Attach to Image CCK

Image attach module is good and quick way for having one image attached per node. But after having used on your site, later you might realize that you need more than one image per node, and you want to use CCK image field for it.

The problem is that you already have many images attached to your nodes.

Don't despair there is a quick and easy way to migrate your image attach images to your new CCK field.