0
我找到了一些關於將substr()添加到變量但不添加到函數的教程。在HTML輸出到目前爲止是:將substr()添加到<?php the_title();?>
<div class="symbol"><?php the_title();?></h3>
裏面the_title()
當我下面的函數在它懸停在Eclipse中它顯示:
function = the_title($before = '', $after = '', $echo = true){
$title = get_the_title();
if (strlen($title) == 0)
return
$title = $before . $title . $after
if ($echo)
echo $title;
else
...
我只是不確定自己是否需要添加到功能在後端頁面中,或者我可以在前端對其進行編碼。
讓PHP找到最近完成的單詞,有12個字符有限(上面的代碼) – lxm7