簡體   English   中英

刪除超鏈接標題-wordpress

[英]removing hyperlink title - wordpress

谷歌搜索后,我發現了很多類似的結果。

搜索: <a href="<? php the_permalink()" /> <?php the_title()?> </a>

在主題目錄中的single.php或page.php或index.php中。

我找不到方法(只是尋找標題,而不是整個句子)。

我使用的是Fastfood主題,而且我一直在尋找single.php,page.php和index.php(所有這些文件均為1或2Kb,因此Im不會在搜索中失敗。

'C:... \\ apache2 \\ htdocs \\ wordpress \\ wp-content \\ themes \\ fastfood \\'這是我正在看的目錄。

有人知道我必須查看哪個文件/目錄嗎?

謝謝您的寶貴時間。

編輯:都不在header.php中,但足夠接近:

如果您使用的是Linux或MacSOX,則可以使用find命令,打開終端,進入主題文件夾並鍵入

find . -type f -name \*.php -print0 | xargs -0 grep -i the_title()

您將看到the_title()的使用位置,然后可以對其進行修改。

使用Windows –我不太了解,請檢查該鏈接: http : //msdn.microsoft.com/zh-cn/library/017ybd7t (v=VS.80) .aspx

編輯

在Windoze中, find的替代方法似乎是findstr ,嘗試類似

FINDSTR / s / i the_title()* .php

functions.php找到名為fastfood_featured_title的函數。 更改以下行:

if ( $post_title || $thumb ) $post_title = '<h2 class="' . $title_class . '"><a title="' . $args['title'] . '" href="' . $args['href'] . '"' . $link_target . ' rel="bookmark">' . $thumb . $post_title . '</a></h2>';

至:

if ( $post_title || $thumb ) $post_title = '<h2 class="' . $title_class . '">' . $thumb . $post_title . '</h2>';

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM