Schon mal vielen Dank für den Hinweise! Ich hatte es mit dem Plugin 'Shortcoder' probiert. Gleiches Ergebnis.
Nun habe ich mich daran gewagt, dass ganze direkt in WP zu implementieren in der functions.php. Allerdings erhalte ich noch einen Fehler beim Aufruf der Seite nun:
Parse error: syntax error, unexpected '<' ...../functions.php on line 23
Der Shortcode in meiner functions.php
function get_bmlogin() {
<script type="text/javascript">// < ![CDATA[
var config = {
"loginPage": "https://bm.bm-od.com/bm",
"homePage": 1,
"width": "256px",
"height": "310px"
};
var url = config.loginPage + '?homePage=1';
var message = getMessage('message');
if (message != null) {
url += "&message=" + message;
}
//only for test bootstrap mode, this should be removed
//if(isBootstrapMode()) {
url += "&uiMode=bootstrap";
//}
function getMessage(name) {
var url = document.URL,
i = url.indexOf(name += '='),
j = url.indexOf('&', i);
if (-1 == j) {
j = url.length;
}
if (-1 != i) {
return url.substring(i + name.length, j);
}
return null;
}
function isBootstrapMode() {
//read current url params to check this
var queryParams = window.location.search.substring(0);
if (queryParams.indexOf("uiMode=bootstrap") != -1) {
return true;
}
return false;
}
document.write('<iframe src="' + url + '" frameborder="0" id="loginIFrame" width="' + config.width + '" height="' + config.height + '" scrolling="no" allowtransparency="true">');
// ]]></script>
}
add_shortcode( 'bmlogin', 'get_bmlogin' );
Ihn stört die '<' Klammer vor dem Script. Wo liegt mein Fehler?