Tag Archives: Drupal

Drupal 7 – Setup Apache Solr for site search

1. Download Apache Solr 3.4 and extract it.
 

2. Also download the Drupal Apache Solr Search Integration module.
 

3. In the extracted Solr folder. go to ./example/solr/conf.
 

4. Backup the following files by rename them. Continue reading Drupal 7 – Setup Apache Solr for site search

Drupal – Add Extra jQuery Library

Next: Drupal 7 – Add the latest jQuery on your Drupal 7 without conflicts

The jQuery Update module allows us to update the Drupal 6 core jQuery to 1.3.2. This is definitely not enough for many 3rd party jQuery libraries. If you want to add the latest jQuery without affecting the core script, you can try the following approach which makes use of the jQuery.noConflict() and it is originally written by gala4th in his blog THERE IS NO PLACE LIKE 127.0.0.1.

Ok, now we want to add the new jQuery for a specific content. Let’s follow the custom module we created in Continue reading Drupal – Add Extra jQuery Library

Python – Install a Python2.5 on Ubuntu Lucid @ 1

A few months ago i was working on a Drupal CDN setup using the Drupal CDN module and File Conveyor written by Wim Leers. But i have some problems when running the File Conveyor. At first, i thought it is because Python version. Ubuntu 10.04 (Lucid) comes with Python 2.6 but i wanna run the File Conveyor in 2.5. (*Finally i found that the switching the Python version would not resolve the problem.)

There are 2 ways to install additional Python package.
By apt-get Continue reading Python – Install a Python2.5 on Ubuntu Lucid @ 1

Drupal – Theme node template by module

Suppose we have a content type called Silly Question. We can theme the node template by adding the node-silly_question.tpl.php in the theme folder. But if we are working on a module, we should ask Drupal to read the .tpl.php in our module folder first because we shouldn’t ask the module user to copy the .tpl.php from our module folder to their theme folder.
Continue reading Drupal – Theme node template by module

Drupal – Introduction to Drupal Theming @ 3

Update @ 20130303: For Drupal 7, please refer to the following post.
Drupal 7 – Create your own theme function on your custom block

 

Previous related articles
Drupal – Introduction to Drupal Theming @ 1
Drupal – Introduction to Drupal Theming @ 2

So we could now use a .tpl.php for our customized content. The last thing i would like to mention is about the preprocess function.

Suppose i want to load a node content on the .tpl.php, we can either include the node as an arguments when calling the theme function like. Continue reading Drupal – Introduction to Drupal Theming @ 3