BuddyPress in einem Unterblog einer WP 3.0 Multisite

Das Buddypress Plugin kann nur netzwerkweit aktiviert werden. Soll buddypress in einem Unterblog einer Multisite installiert werden statt auf der Hauptseite, so kann man den Unterblog mit Hilfe des folgenden Eintrags in der wp-config.php als Rootblog definieren:

define ( 'BP_ROOT_BLOG', $blog_id );

Beispiel:

define ( 'BP_ROOT_BLOG', 3 );
Veröffentlicht unter Allgemein | Hinterlasse einen Kommentar

Custom Post Types / Custom Taxonomies

Seit WordPress 3.0 ist es möglich, eigene Inhaltstypen zu erstellen. Hierzu steht die Funktion register_post_type(); zur Verfügung.

Beispiel: Erstellung eines Inhaltstyps ‘Buch’

add_action( 'init', 'create_post_type' );
function create_post_type() {
register_post_type( 'buch',
array(
'labels' => array(
'name' => __( 'Bücher' ),
'singular_name' => __( 'Buch' )
),
'public' => true,
)
);
}

Der Funktion register_post_type(); können eine Reihe von Argumenten mitgegeben werden

Standardmäßig gibt es bei WordPress drei Taxonomie-Typen: Kategorien für Artikel, Kategorien für Links und Tags.

Mit der Funktion register_taxonomy(); ist es möglich, eigene Taxonomie-Typen zu erstellen und diese einem Inhaltstyp zuzuordnen.

Beispiel:

//neue Funktion per add_action an den ‘init’ hook binden
add_action( ‘init’, ‘create_book_taxonomies’, 0 );

//zwei Taxonimen für den Inhaltstyp “Buch” erstellen: Genre und Autoren
function create_book_taxonomies()
{
// Neue hierarchische kategorieähnliche Taxonomien erstellen
$labels = array(
‘name’ => _x( ‘Genres’, ‘taxonomy general name’ ),
‘singular_name’ => _x( ‘Genre’, ‘taxonomy singular name’ ),
‘search_items’ =>  __( ‘Suche Genres’ ),
‘all_items’ => __( ‘Alle Genres’ ),
‘parent_item’ => __( ‘Hauptgenre’ ),
‘parent_item_colon’ => __( ‘Hauptgenre:’ ),
‘edit_item’ => __( ‘Genre bearbeiten’ ),
‘update_item’ => __( ‘Genre aktualisieren’ ),
‘add_new_item’ => __( ‘Genre hinzufügen’ ),
‘new_item_name’ => __( ‘Neues Genre’ ),
);

register_taxonomy(‘genre’,array(‘buch’), array(
‘hierarchical’ => true,
‘labels’ => $labels,
‘show_ui’ => true,
‘query_var’ => true,
‘rewrite’ => array( ‘slug’ => ‘genre’ ),
));

// Add new taxonomy, NOT hierarchical (like tags)
$labels = array(
‘name’ => _x( ‘Autoren’, ‘taxonomy general name’ ),
‘singular_name’ => _x( ‘Autor’, ‘taxonomy singular name’ ),
‘search_items’ =>  __( ‘Autor suchen’ ),
‘popular_items’ => __( ‘Beliebte Autoren’ ),
‘all_items’ => __( ‘Alle Autoren’ ),
‘parent_item’ => null,
‘parent_item_colon’ => null,
‘edit_item’ => __( ‘Autor bearbeiten’ ),
‘update_item’ => __( ‘Autor aktualisieren’ ),
‘add_new_item’ => __( ‘Autor hinzufügen’ ),
‘new_item_name’ => __( ‘Neuer Autor’ ),
‘separate_items_with_commas’ => __( ‘Mehrere Autoren mit Komma trennen’ ),
‘add_or_remove_items’ => __( ‘Autoren entfernen oder hinzufügen’ ),
‘choose_from_most_used’ => __( ‘Choose from the most used writers’ )
);

register_taxonomy(‘autor’,'buch’,array(
‘hierarchical’ => false,
‘labels’ => $labels,
‘show_ui’ => true,
‘query_var’ => true,
‘rewrite’ => array( ‘slug’ => ‘autor’ ),
));
}

Um den neuen Inhaltstyp auf der Webseite auszugeben, gibt es für die Darstellung einer Seite, die alle Artikel eines Inhaltstyps auflistet das Plugin Simple Custom Post Types. Nach Installation muss man nun nur noch ein Kategorietemplate für den neuen Inhaltspunkt erstellen und diese dann unter type-(custom-post-type-name).php im Themeordner abzuspeichern (im Falle des obigen Beispiels also type-buch.php).

Alternativ kann man auch selber die Wiedergabe über einen Eintrag in der functions.php steuern, indem man den template_redirect Hook benutzt werden (Beispiel)

Veröffentlicht unter Allgemein | Hinterlasse einen Kommentar

Hallo Welt!

Willkommen zur deutschen Version von WordPress. Dies ist der erste Artikel. Du kannst ihn bearbeiten oder löschen. Um Spam zu vermeiden, geh doch gleich mal in den Pluginbereich und aktivier die entsprechenden Plugins. So, und nun genug geschwafelt – jetzt nichts wie ran ans Bloggen!

Veröffentlicht unter Allgemein | 1 Kommentar

Softie Earings

Price: 25

Select Size

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam tristique eleifend consectetur. Proin molestie ultricies vehicula. Suspendisse tempus pellentesque mi in commodo. Curabitur bibendum urna non ipsum accumsan iaculis. Nulla porttitor consectetur orci, vitae ullamcorper metus sodales ac. Nulla eleifend sapien non felis vulputate elementum in vel nunc. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Veröffentlicht unter Products | Kommentare deaktiviert

Sunshine Earings

Price: 25

Select Size

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam tristique eleifend consectetur. Proin molestie ultricies vehicula. Suspendisse tempus pellentesque mi in commodo. Curabitur bibendum urna non ipsum accumsan iaculis. Nulla porttitor consectetur orci, vitae ullamcorper metus sodales ac. Nulla eleifend sapien non felis vulputate elementum in vel nunc. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Veröffentlicht unter Products | Kommentare deaktiviert

Goatman Mask

Price: 225

Select Size

Skin-covered masks in Africa are found only in southeastern Nigeria and western Cameroon. Historical evidence suggests that the peoples of this region regard skin as a substance associated with the spirits of the dead and their animal counterparts. The facial features are realistically portrayed. The spiral horns are similar to the hairstyles worn by girls during a ceremony marking the end of their seclusion prior to marriage.

Veröffentlicht unter Products | Kommentare deaktiviert

Double Vessels

Price: 300

Select Size

The inhabitants of the mountainous Kabyle region along the Mediterranean coast in northeastern Algeria are primarily farmers. They are also superb artists noted for their jewelry making, textiles, mats, basketry, pottery and house mural decoration. In North Africa, wheel-thrown pottery made by men dates from the 7th century B.C. when the Phoenicians introduced the potter’s wheel to the Algerian coast. Handbuilt pottery made by women, including those from the Kabyle, an older, probably indigenous tradition, dates back 2000 years before the birth of Christ. The vessel depicted here originates from earlier prototypes. To this day, Kabyle women coil and decorate pottery with beautiful painted geometric designs for their own household use and for sale. Kabyle women handbuild vessels of various sizes and shapes for holding water, milk, oil, cooking and eating food, and oil lamps. This vessel (thibuk’alin) was probably created for local use. It is composed of two interconnected containers joined at the neck and body by two channels through which liquid can flow. Each container has a pouring spout. Such vessels may have been used to pour libations or offerings during a ritual. This vessel, colored with white slip, decorated with black geometric designs and with a short, thick body and flat bottom, probably originated in the Little Kabyle area in eastern Algeria. The zigzag designs may refer to either a serpent or a fish, both thought to have apotropaic functions to counter evil. The bottom of this pot contains a potter’s mark consisting of a rectangular shape with cross-hatched lines.

Veröffentlicht unter Products | Kommentare deaktiviert

Teke Vessels

Price: 100

Select Size

The dynamic sculptural quality of this vessel is enhanced by the sweeping curves of its handles and its firmly planted feet. The allusion to the human body is unmistakable. The vessel is probably an early example of ceramic art made for the increasing numbers of Europeans visiting the region after the turn of the 20th century.

Veröffentlicht unter Products | Kommentare deaktiviert

Yoruba Armlets

Price: 50

Select Size

This pair of armlets may have been part of the regalia of the Olowo of Owo, a Yoruba king. The motifs evoke the spiritual forces that shape the world and are controlled by the ruler. The head with creatures issuing from the nostrils suggests the loosing of inner spiritual forces. Similarly the fish-legged figure is a being that transcends the realms of land and water and symbolizes Olokun, god of the sea.

Veröffentlicht unter Products | Kommentare deaktiviert

Kabyle Jar

Price: 175

Select Size

The inhabitants of the mountainous Kabyle region along the Mediterranean coast in northeastern Algeria are farmers primarily. They are also superb artists noted for their jewelry, textiles, mats, basketry, pottery and house murals. In North Africa, wheel-thrown pottery, which is made by men, dates from the 7th century B.C. when the Phoenicians introduced the potter’s wheel to the Algerian coast. Handbuilt pottery, which is made by women, is an older, probably indigenous tradition that dates back 2000 years before the birth of Christ. To this day, Kabyle women coil and decorate pottery with beautiful, geometric designs for their own household use and for sale. Kabyle women handbuild vessels of various sizes and shapes for holding water, milk and oil, for cooking and eating food and for making oil lamps. This vessel with the head of an animal (possibly a camel) may have been made for visiting foreigners.

Veröffentlicht unter Products | Kommentare deaktiviert