Hi!
Da meine Suche im Forum leider bisher keine Treffer erzielt hat versuche ich es in einem neuen Thread.
Ich habe ein neues Template erstellt und in der functions.php zwei Shortcodes erstellt:
PHP
function scBlack($atts = null, $content = null) {
return '<div class="black">'.$content.'</div>';
}
function scClear() {
return '<div class="clear"></div>';
}
add_shortcode('black', 'scBlack');
add_shortcode('clear', 'scClear');
Alles anzeigen
Aus irgendeinem Grund wird immer nur ein Shortcode umgesetzt. Wenn ich add_shortcode für black auskommentiere funktioniert der Shortcode für clear und andersherum.
Es handelt sich um eine statische Seite die folgenden HTML Code enthält:
HTML
[black]
<img class="css-klasse float nach links" title="bildtitle" src="pfad/zum/bild.jpg" alt="" width="315" height="437" />
<h1>headline.</h1>
<h2>subheadline.</h2>
Text text text text text text text text .[/black][clear]
Ich hoffe jemand kann mir helfen und das Problem erläutern... :confused: Ich danke euch um Vorraus!