Slowakei.com - German-language business portal about Slovakia

tobiasr - May 29, 2007 - 15:15

Hi,

we launched http://www.slowakei.com a couple of weeks ago on Drupal 5.1. It serves as a portal site about the Slovakian business environment.

The design was done partly by a freelance designer and then implemented into a Drupal theme by Jeroen Coumans (http://www.jeroencoumans.nl/), who was excellent to work with.

The site uses quite a few modules. On the core side, we use
- pathauto for clean URLs (with a hack not to remove Umlauts)
- global redirect
- frontpage to make the first page more customizable

On the nodes, we use:
- meta tags
- related links
- freetagging
- tagadelic
- jrating

For the community (even if there is none yet :) we use:
- ed_classified
- userlinks
- userpoints

On the frontpage, we also use the weather module and currency_api for the Ajaxified currency checker.

The frontpage had initially 220 DB queries and with blockcache we were able to reduce that to 55.

I'd appreciate any feedback and criticism and will be happy to answer any questions you might have.

-Tobias

Looks clean _ like it

George311 - May 29, 2007 - 20:06

Looks clean .... good job.

How did you add the Keywords and description?

We can all make it happen!

Keywords

tobiasr - May 30, 2007 - 06:54

Hi,

do you mean the meta tags? There is a metatags module for that.

Other "keywords" are the freetagging tags.

-Tobias

Pathauto

DesignWork - May 31, 2007 - 16:04

Hi Tobias,

i´m working on a german drupal page http://www.freelens.ws/dirksway

How did you hacked pathauto for clean URLs (with a hack not to remove Umlauts) is there a patch for this?
Or can you provide the hack?

Cheers from Cologne

Dirk

Hi Dirk, this is the diff

tobiasr - May 31, 2007 - 17:48

Hi Dirk,

this is the diff between our pathauto.module and the original one. I believe we based this on a patch from the pathauto project but unfortunately I don't have the original reference.

Also note that this will actually preserve Umlauts as-is. Sometimes it may make more sense to use the transliteration (ä becomes ae). In our case we wanted to keep Umlauts because Google indexes them quite well by now.

-jailshell-2.05b$ diff pathauto.module pathauto.module.orig
94,98d93
<   $form["general"]["pathauto_transliterate"] = array('#type' => 'checkbox',
<     '#title' => t('Transliterate prior to creating alias'),
<     '#default_value' => variable_get('pathauto_transliterate', FALSE),
<     '#description' => t('When a pattern includes certain characters (such as those with accents) should Pathauto attempt to transliterate them into the ASCII-96 alphabet?'));
<
234a230,241
>   static $i18n_loaded = false;
>   static $translations = array();
>   if (!$i18n_loaded) {
>     $path = drupal_get_path('module', 'pathauto');
>     if (is_file($path. '/i18n-ascii.txt')) {
>       $translations = parse_ini_file($path. '/i18n-ascii.txt');
>     }
>     $i18n_loaded = true;
>   }
>
>   $output = strtr($output, $translations);
>
239a247,261
>   // Convert accented characters to their ASCII counterparts...
> /*  $output = strtr(utf8_decode($output),
>        "\xA1\xAA\xBA\xBF".
>        "\xC0\xC1\xC2\xC3\xC5\xC7\xC8\xC9\xCA\xCB\xCC\xCD\xCE\xCF".
>        "\xD0\xD1\xD2\xD3\xD4\xD5\xD8\xD9\xDA\xDB\xDD".
>        "\xE0\xE1\xE2\xE3\xE5\xE7\xE8\xE9\xEA\xEB\xEC\xED\xEE\xEF".
>        "\xF0\xF1\xF2\xF3\xF4\xF5\xF8\xF9\xFA\xFB\xFD\xFF",
>        "!ao?AAAAACEEEEIIIIDNOOOOOUUUYaaaaaceeeeiiiidnooooouuuyy");
>   */
>   // ...and ligatures too
>   $output = utf8_encode(strtr($output, array("\xC4"=>"Ae", "\xC6"=>"AE", "\xD6"=>"Oe",
>     "\xDC"=>"Ue", "\xDE"=>"TH", "\xDF"=>"ss", "\xE4"=>"ae", "\xE6"=>"ae",
>     "\xF6"=>"oe", "\xFC"=>"ue", "\xFE"=>"th")));
>   $output = strtr($output, $translations);
>
244,265c266,268
<   // Optionally remove accents and transliterate to a subset of ASCII-96 characters.
<   if (variable_get('pathauto_transliterate', FALSE)) {
<
<     static $i18n_loaded = false;
<     static $translations = array();
<     if (!$i18n_loaded) {
<       $path = drupal_get_path('module', 'pathauto');
<       if (is_file($path. '/i18n-ascii.txt')) {
<         $translations = parse_ini_file($path. '/i18n-ascii.txt');
<       }
<       $i18n_loaded = true;
<     }
<
<     $output = strtr($output, $translations);
<
<     // Preserve alphanumerics, everything else becomes a separator.
<     $pattern = '/[^a-zA-Z0-9]+/ ';
<     $output = preg_replace($pattern, $separator, $output);
<   }
<
<   // Always replace whitespace with the separator.
<   $output = preg_replace("/\s+/", $separator, $output);
---
>   // Preserve alphanumerics, everything else becomes a separator
>   $pattern = '/[^a-zA-Z0-9]+/ ';
>   $output = preg_replace($pattern, $separator, $output);

-Tobias

Thanks

DesignWork - June 1, 2007 - 01:22

Hi Tobias,

thanks for the patch. I apllied it but it seems that it is not working for me?

Dirk

Did you rerun the pathauto

tobiasr - June 1, 2007 - 07:51

Did you rerun the pathauto alias generation?

 
 

Drupal is a registered trademark of Dries Buytaert.