image_send_to_editor_url WordPress Filter Hook

The image_send_to_editor_url hook allows you to modify the URL of the image that is inserted into the post editor when using the Add Media button. This can be useful if you want to use a different image hosting service or if you want to change the size of the image that is inserted.

apply_filters( 'image_send_to_editor_url', string $html, string $src, string $alt, string $align ) #

Filters the image URL sent to the editor.


Parameters

$html

(string)HTML markup sent to the editor for an image.

$src

(string)Image source URL.

$alt

(string)Image alternate, or alt, text.

$align

(string)The image alignment. Default 'alignnone'. Possible values include 'alignleft', 'aligncenter', 'alignright', 'alignnone'.


Top ↑

Source

File: wp-admin/includes/media.php

View on Trac



Top ↑

Changelog

Changelog
VersionDescription
2.8.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.

Show More
Show More