Title: Append User ID
Author: mrdl
Published: <strong>2020 年 1 月 16 日</strong>
Last modified: 2020 年 1 月 16 日

---

搜索插件

![](https://ps.w.org/append-user-id/assets/banner-772x250.png?rev=2228344)

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://ps.w.org/append-user-id/assets/icon-256x256.png?rev=2228344)

# Append User ID

 作者：[mrdl](https://profiles.wordpress.org/mardellme/)

[下载](https://downloads.wordpress.org/plugin/append-user-id.1.0.0.zip)

 * [详情](https://cn.wordpress.org/plugins/append-user-id/#description)
 * [评价](https://cn.wordpress.org/plugins/append-user-id/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/append-user-id/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/append-user-id/#developers)

 [支持](https://wordpress.org/support/plugin/append-user-id/)

## 描述

Adds the current logged in user ID to a specified string

    ```
    [user_link url="https://domain.com/link"]A link[/user_link]
    ```

Will output the following HTML

    ```
    <a href="https://domain.com/link?user_id=1">A link<a/>
    ```

## 屏幕截图

 * [[
 * Frontend view

## 安装

This section describes how to install the plugin and get it working.

 1. Upload the plugin files to the `/wp-content/plugins/append-user-id` directory, 
    or install the plugin through the WordPress plugins screen directly.
 2. Activate the plugin through the ‘Plugins’ screen in WordPress

## 常见问题

  How do I change the HTML output?

There are a few filters available to override certain parts of the output. The
 
main filter is `append_id_content` and can be used as follows:

    ```
    /**
     * Change HTML output
     */
     function your_theme_append_id_content ( $html, $url, $content ) {
        $link_html = '<a id="your_id" href="' . esc_url( $url ) . '">';
        $link_html .= esc_html( $content );
        $link_html .= '</a>';

        return $link_html;
     }
     add_filter( 'append_id_content', 'your_theme_append_id_content', 10, 3 );
    ```

## 评价

此插件暂无评价。

## 贡献者及开发者

「Append User ID」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ mrdl ](https://profiles.wordpress.org/mardellme/)

[帮助将「Append User ID」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/append-user-id)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/append-user-id/)，查看
[SVN仓库](https://plugins.svn.wordpress.org/append-user-id/)，或通过[RSS](https://plugins.trac.wordpress.org/log/append-user-id/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/append-user-id/)。

## 更新日志

#### 1.0.0

 * Initial release.

## 额外信息

 *  版本 **1.0.0**
 *  最后更新：**6 年前**
 *  活跃安装数量 **10+**
 *  WordPress 版本 ** 4.0 或更高版本 **
 *  已测试的最高版本为 **5.3.21**
 *  PHP 版本 ** 5.6 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/append-user-id/)
 * 标签
 * [string](https://cn.wordpress.org/plugins/tags/string/)[tag](https://cn.wordpress.org/plugins/tags/tag/)
   [url](https://cn.wordpress.org/plugins/tags/url/)[userid](https://cn.wordpress.org/plugins/tags/userid/)
 *  [高级视图](https://cn.wordpress.org/plugins/append-user-id/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/append-user-id/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/append-user-id/reviews/)

## 贡献者

 *   [ mrdl ](https://profiles.wordpress.org/mardellme/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/append-user-id/)