Block Editor: Coding standards, properly escape class names.
Props: aduth, noisysocks, pento, talldanwp, jorgefilipecosta, whyisjake, ellatrix, ehti. git-svn-id: https://develop.svn.wordpress.org/trunk@47636 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
8e11facb67
commit
ec05c8b897
@ -92,7 +92,7 @@ function render_block_core_rss( $attributes ) {
|
||||
$class .= ' ' . $attributes['className'];
|
||||
}
|
||||
|
||||
return "<ul class='{$class}'>{$list_items}</ul>";
|
||||
return sprintf( "<ul class='%s'>%s</ul>", esc_attr( $class ), $list_items );
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -57,7 +57,7 @@ function render_block_core_search( $attributes ) {
|
||||
|
||||
return sprintf(
|
||||
'<form class="%s" role="search" method="get" action="%s">%s</form>',
|
||||
$class,
|
||||
esc_attr( $class ),
|
||||
esc_url( home_url( '/' ) ),
|
||||
$label_markup . $input_markup . $button_markup
|
||||
);
|
||||
|
Loading…
Reference in New Issue
Block a user