Этот плагин не тестировался с последними 3 основными выпусками WordPress. Скорее всего, он уже не поддерживается и может быть несовместим с текущими версиями WordPress.

DCO Comment Attachment

Описание

DCO Comment Attachment позволяет посетителям прикреплять к своим комментариям изображения, видео, аудио, документы и другие файлы. Они также смогут автоматически вставлять в текст комментария ссылки с Youtube, Facebook, Twitter и других сервисов.

С помощью настроек плагина вы можете:

  • Ограничить максимальный размер загружаемого файла.
  • Сделать вложение обязательным.
  • Укажите, нужно ли встраивать вложение или будет отображаться ссылка.
  • Включение/отключение автоматического размещения встраиваемого содержимого ссылки (например, Youtube, Facebook, Twitter и т.д.) в текст комментария.
  • Выберите размер прикрепляемого изображения из размеров миниатюр, доступных в вашей установке WordPress.
  • Ссылка миниатюры на полноразмерное изображение с поддержкой плагинов лайтбокс (подробности в разделе Чаво)
  • Open a full-size image in a new tab or link thumbnail to the attachment page.
  • Включить/отключить множественную загрузку.
  • Объединить изображения в галерею.
  • Выберите размер изображения вложения для галереи изображений.
  • Ограничение типов файлов вложений.
  • Укажите, кто сможет загружать вложения: все пользователи или только авторизованные.
  • Manually moderate comments with attachments.

Вы также можете:

  • Добавление, замена или удаление вложения комментария на экране редактирования комментариев.
  • Прикрепляйте неограниченное количество файлов к комментарию в панели администратора.
  • Delete an attachment from a specific comment or bulk delete attachments from comments on the Comments screen.
  • Display attachments attached to comments to the current post (or a specific post) with the [dco_ca] shortcode. You can also filter by type. See FAQ for details.

Вложения загружаются в библиотеку WordPress и удаляются вместе с комментарием (если это задано в настройках).

Поддерживается REST API.

DCO Comment Attachment также доступен на GitHub.

Скриншоты

  • Примеры типов вложений.
  • Форма комментария с полем вложения.
  • Список комментариев в админ-панели.
  • Экран редактирования комментария в панели администратора.
  • Страница настроек плагина.
  • Пример лайтбокса с плагином Simple Lightbox.
  • An example of a drag and drop support.
  • An example of the new comment notification email.
  • Пример поддержки REST API.

Установка

  1. Загрузите папку dco-comment-attachment в каталог /wp-content/plugins/
  2. Активируйте плагин в разделе «Плагины».

Часто задаваемые вопросы

Какие лайтбокс-плагины поддерживаются?

DCO Comment Attachment протестирован с:
* Simple Lightbox
* Easy FancyBox
* Responsive Lightbox & Gallery
* FooBox Image Lightbox
* FancyBox for WordPress

Feel free to create a new topic on support forum if you need integration with another plugin.

How to use the [dco_ca] shortcode?

Without attributes specified, the [dco_ca] shortcode will display all attachments attached to current post.

You can filter attachments using the type attribute. By default it is all. Also supported: image, video, audio and misc.
You can specify one value [dco_ca type="image"] or multiple values, separated by commas [dco_ca type="video,audio"].

You can also display attachments from the comments of another post using the post_id attribute.
For example, [dco_ca post_id="45"], where 45 is the ID of the specific post.

You can also combine these attributes. For example, [dco_ca post_id="45" type="image"] will display all images attached to comments to the post with ID 45.

Отзывы

14.08.2023
Works well. I was able to limit file type and see the jpg in the admin comment approval area and then image displayed nicely in the comments.
14.04.2023
its a great plugin i have a suggest there is a bad thing about uploaded file by user is that its going go wordpress media location. it make hard to find and categorize uploaded file by user for owner of site. if it save file on another location that we could great
31.10.2022
This is an awesome plugin. I've been looking for something like this a long time. I hope the author Denis will keep update this plugin and won't abandon like others after a while. Just wondering, for some reason I have to disable your plugin, all the Youtube links and image attachements will be turned off too?
05.12.2021 1 ответ
im trying to translate to translate plugi strings such as ( The maximum upload file size, Attachment, etc) with loco translate, but the translation not working at the front end. how can i translate the strings ?
Посмотреть все 9 отзывов

Участники и разработчики

«DCO Comment Attachment» — проект с открытым исходным кодом. В развитие плагина внесли свой вклад следующие участники:

Участники

«DCO Comment Attachment» переведён на 6 языков. Благодарим переводчиков за их работу.

Перевести «DCO Comment Attachment» на ваш язык.

Заинтересованы в разработке?

Посмотрите код, проверьте SVN репозиторий, или подпишитесь на журнал разработки по RSS.

Журнал изменений

2.4.0

  • Added bulk delete attachments action on the Comments screen.
  • Added the [dco_ca] shortcode for display attachments attached to comments (see FAQ for details).
  • Fixed bug: now if there is no attachment, the empty array is not saved to the database.

2.3.1

  • Fixed a bug with the accept attribute of the attachment upload field.
  • Added compatibility with Loco Translate plugin.

2.3.0

  • Added allowed file types to the file input dialog box. (thank you @pranciskus)
  • Added REST API support (thank you @daohoangson)
  • Added dco_ca_force_download_misc_attachments filter for force download files instead of open.
  • Improved check/uncheck allowed file types on Settings page.
  • Fixed «Trying to get property ‘comment_ID’ of non-object» bug. (thank you @pranciskus)

2.2.0

  • Added drag and drop support for attachment input field.
  • Improved «Link thumbnail?» option. Link to a new tab and an attachment page (thank you @nourijp) is now supported.
  • Fixed bug with «Manually moderate comments with attachments» option. (thank you @thompro)
  • Removed «Attach to commented post?» option from the Settings page. You can use the dco_ca_attach_to_post filter instead.

2.1.1

  • Added new filters for the attachment markup customization: dco_ca_get_attachment_preview and dco_ca_get_attachment_preview_image.

2.1.0

  • Added links to attached attachments to the new comment notification email.
  • Added the feature to force moderation comments with attachments.
  • Added compatible with SVG Support plugin.

2.0.0

  • Добавлена возможность загружать несколько файлов.
  • Добавлена поддержка некоторых лайтбокс-плагинов (см. подробности в FAQ).
  • Added additional markup to the form elements (thank you @matthewmcvickar)
  • Added error handling for JavaScript on the frontend (thank you @mrbalkon)
  • Улучшена страница настроек
  • Фильтр dco_ca_form_element_autoembed_links_notification устарел. Вместо этого используйте dco_ca_form_element_autoembed_links.
  • Тип autoembed-links-notification функции form_element устарел. Вместо него используйте autoembed-links.

1.3.1

  • Fixed image embed bug when attachment url has get parameters (thank you @deepreef)

1.3.0

  • Добавлена возможность связать миниатюру с полноразмерным изображением.
  • Добавлена функция разрешения загрузки вложений только авторизованным пользователям.
  • Добавлено уведомление об автоматически встроенных ссылках, когда функция включена.
  • Fixed bug with incorrect display of attachment types that do not support embedding. (thank you @nazzareno)
  • Убрана зависимость от jQuery на фронтэнде.

1.2.1

  • Fixed Quick Edit Comment function bug (thank you @bbceg)

1.2.0

  • Добавлена возможность автоматического размещения встраиваемого содержимого ссылки в текст комментария. Можно отключить в настройках -> DCO Comment Attachment.
  • Представлен хук dco_ca_disable_display_attachment. Теперь вложение можно отображать в произвольном месте с помощью фильтра add_filter('dco_ca_disable_display_attachment', '__return_true'); и функции dco_ca()->display_attachment().

1.1.2

  • Fixed display of empty allowed types if the website administrator has forbidden the upload of all extensions of this type. (thank you @nunofrsilva)

1.1.1

  • Добавлены фильтры для настройки поля вложения.

1.1.0

  • Теперь можно выбрать и отменить выбор разрешенных типов файлов по типу одним щелчком мыши.
  • Добавлен хук dco_ca_disable_attachment_field для отключения поля загрузки вложения.
  • Уменьшен эффект фильтрации mime-типов. Теперь это касается только загрузки вложений в комментарий.
  • Добавлена возможность прикрепления вложения к комментируемому сообщению.

1.0.0

  • Первая версия