wp-greet – Grußkarten mit Permalinks, wp-greet greetcards with permalinks
Die Anfrage wir man seine wp-greet Grußkarten suchmaschinentauglich und SEO-optimiert mit Permalinks versehen kann, habe ich jetzt doch zu häufig gehört, als das ich sie unbeantwortet lassen möchte. Alles was man dazu braucht ist einen Provider, der mod_rewrite zur Verfügung stellt. Dann muss man nur noch die Datei .htaccess im WordPress-Hauptverzeichnis editieren.
Fügt man beispielsweise folgenden Code in die Datei .htaccess ein, so werden alle Aufrufe die auf wp-greet/greetcard/* enden umgeleitet auf http://meinedomain/?page_id=2&gallery=1&image=http://meinedomain/wp-content/gallery/postkarten/*
RewriteEngine on RewriteRule ^wp-greet/greetcard/(.*)$ http://meinedomain/?page_id=2&gallery=1&image=http://meinedomain/wp-content/gallery/postkarten/$1
Dabei steht das Sternchen für den Dateinamen des Grußkartenbildes. Den Pfad zum Bild und zur Seite mit dem Grußkartenformular muss man natürlich anpassen. Im Beispiel findet sich das Grußkartenformular unter http://meinedomain/?page_id=2, die Bilder stehen in der Gallery mit der ID 1 von NextGenGallery und die Bilder liegen im Verzeichnis http://meinedomain/wp-content/gallery/postkarten.
Mehr dazu findet man im Apache mod_rewrite Guide oder der deutschsprachigen Seite über mod_rewrite.
The question about using permalinks for greeting cards raised some times in the past and therefore I want to give a little advice on how you can manage to get to SEO friendly permalinks for you greeting cards using wp-greet. All you need is a provider letting you access mod_rewrite. All you have to do is modify your .htaccess file in the wordpress main directory.
Adding the following code to your .htaccess file will for example, redirect calls to url’s containing wp-greet/greetcard/* to http://mydomain/?page_id=2&gallery=1&image=http://mydomain/wp-content/gallery/postkarten/*
RewriteEngine on RewriteRule ^wp-greet/greetcard/(.*)$ http://mydomain/?page_id=2&gallery=1&image=http://mydomain/wp-content/gallery/postkarten/$1
The * stands for the filename of the greetcard picture. Of course you have to adopt the path for the greetcard form and the pictures. Looking at the example the greetcard form is placed at http://mydomain/?page_id=2, the pictures are stored in the gallery with ID 1 of NextGenGallery and the pictures are stored in the directory http://mydomain/wp-content/gallery/postkarten.
Details about mod_rewrite can be found at the Apache mod_rewrite guide or the german site about mod_rewrite.
Artikel, die auch interessant sein könnten:



















Hello,http://www.tuxlog.de/wp-content/plugins/wp-monalisa/icons/wpml_bye.gif
I hope there is someone there that can read English. I found your WordPress plugin wp-greet and wanted to find out more about it. Is there instructions available in english?
It looks like what I would like to put on our children’s website at our church so that they can send each other birthday cards etc.
If there are english instructions could you please email them to me.
Thank you!
Gordon
hello Gordon,
yes, there is a english documentation of wp-greet. you can find it athttp://www.tuxlog.de/wordpress/2008/wp-greet-documentation-english/. It is for version 2.5 but there are only a few changes to v2.7.
regard, hans
Pingback: wordpress « wp-greet Version 2.5 « Tuxlog