我想刪除Google搜索顯示的元日期。我碰到這個代碼通常在single.php中發現來到使用javascript顯示php時間/日期函數的幫助
<?php the_time(‘M j, Y’);?>
需要重新寫爲:
<script language=」javascript」 type=」text/javascript」> document.write(‘<?php the_time(‘j’) ?>’); </script> <?php the_time(‘M Y’) ?>
但是我single.php中使用這種格式
<?php the_time(get_option('date_format')); ?>
哪有我使用JavaScript的上述代碼?
the_time?從來沒有見過這個,是你自己的功能還是你的框架? – Ibu 2011-05-28 05:40:36
只需使用'date('j')'; – Ibu 2011-05-28 05:41:16