weDocs 將 ‘docs’ 鏈接 slug 更改為 ‘documentation’ 或者其他的方法。

標籤: 

正在查看 1 個帖子:1-1 (共 1 個帖子)
  • 作者
    帖子
  • 詩語
    管理員
    • 文章數量: 5,932
    @feibisi
    樓主

    默認的鏈接形式為 docs , 但還是可以調整的,如下:

    /**
     * Changing the <code>docs</code> slug to something else
     *
     * @param array $args
     *
     * @return array
     */
    add_filter( 'wedocs_post_type', function($args) {
    
        $args['rewrite']['slug'] = 'documentation';
    
        return $args;
    } );
正在查看 1 個帖子:1-1 (共 1 個帖子)
  • 哎呀,回覆話題必需登錄。

話題信息

  • 當前位於:功能改進
  • 0 條回覆
  • 1 個參與人
  • 最後回覆:<a href="https://bbs.weixiaoduo.com/users/feibisi/" title=" 查看詩語的個人資料" class="bbp-author-link"><span class="bbp-author-name"> 詩語</span></a>
  • 上次活動:<a href="https://bbs.weixiaoduo.com/topic/28016/" title="weDocs 將 'docs' 鏈接 slug 更改為 'documentation' 或者其他的方法。">6 年、 7 月前</a>