WP-discourse: how to deal with shortcodes in post

こんにちは @simon さん

あなたのテンプレートを使って discourse_publish_format_html をカスタマイズし、すべての投稿を iframe で表示するようにしました。しかし、出力される iframe の src パラメータが空になっています。こちらをご覧ください:

https://forum.cannabisanbauen.net/t/ist-meine-pflanze-maennlich-was-tun/7196

なぜでしょうか? 以下が私のコードです:

// 投稿を iframe で表示
function your_namespace_publish_format_html( $output ) {
    global $post;
	?>
    <iframe width="690" height="2000" src="<?php echo esc_url( the_permalink() ); ?>" frameborder="0"></iframe>
	<?php
	$output = ob_get_clean();

    // デフォルトの出力を返すか、ここで他の処理を行います。
    return $output;
}
add_filter( 'discourse_publish_format_html', 'your_namespace_publish_format_html' );