<h2>xxx</h2>
add_editor_style( 'editor-styles.css' );
с s на конце и все работало.<h2 clear: both;>
<h2></h2>
Можно как то сделать?function removeHomeUrl($url)
{
$url_sectors = preg_split('/\//i', $url);
unset($url_sectors[0]);
unset($url_sectors[1]);
unset($url_sectors[2]);
return '/'.join('/', $url_sectors);
}
add_filter('plugins_url', 'removeHomeUrl');
function attachment_image($attrs)
{
$url_sectors = preg_split('/\//', $attrs['src']);
unset($url_sectors[0]);
unset($url_sectors[1]);
unset($url_sectors[2]);
$attrs['src'] = '/'.join('/', $url_sectors);
return $attrs;
}
add_filter('wp_get_attachment_image_attributes', 'attachment_image');
function removeHomeUrl($url)
{
$url_sectors = preg_split('/\//i', $url);
unset($url_sectors[0]);
unset($url_sectors[1]);
unset($url_sectors[2]);
return '/'.join('/', $url_sectors);
}
add_filter('plugins_url', 'removeHomeUrl');
function attachment_image($attrs)
{
$url_sectors = preg_split('/\//', $attrs['src']);
unset($url_sectors[0]);
unset($url_sectors[1]);
unset($url_sectors[2]);
$attrs['src'] = '/'.join('/', $url_sectors);
return $attrs;
}
add_filter('wp_get_attachment_image_attributes', 'attachment_image');
It has been suggested that if WordPress were to be able to do all of this over, we may have instead opted for relative URLs. This is true, and making adjustments to our current approach – or reconsidering it in its entirety – does remain a distinct possibility in the future.