Loading functions.php +2 −2 Original line number Diff line number Diff line Loading @@ -38,8 +38,8 @@ add_filter('upload_mimes', 'fscoli_mime_types', 1, 1); // For more details on the parameters this function is called with, see also // https://developer.wordpress.org/reference/classes/wp_embed/get_embed_handler_html/ function fscoli_embed_umap($regex_matches, $embed_attrs, $url, $raw_embed_attrs) { $width = $embed_attrs['width']; $height = $embed_attrs['height']; $width = $embed_attrs['width'].'px'; $height = $embed_attrs['height'].'px'; return "<iframe src='$url' style='width: $width; height: $height'></iframe>"; } wp_embed_register_handler('umap', '#^https://umap.openstreetmap.de/[a-z]{2}/map/.*#', 'fscoli_embed_umap'); Loading Loading
functions.php +2 −2 Original line number Diff line number Diff line Loading @@ -38,8 +38,8 @@ add_filter('upload_mimes', 'fscoli_mime_types', 1, 1); // For more details on the parameters this function is called with, see also // https://developer.wordpress.org/reference/classes/wp_embed/get_embed_handler_html/ function fscoli_embed_umap($regex_matches, $embed_attrs, $url, $raw_embed_attrs) { $width = $embed_attrs['width']; $height = $embed_attrs['height']; $width = $embed_attrs['width'].'px'; $height = $embed_attrs['height'].'px'; return "<iframe src='$url' style='width: $width; height: $height'></iframe>"; } wp_embed_register_handler('umap', '#^https://umap.openstreetmap.de/[a-z]{2}/map/.*#', 'fscoli_embed_umap'); Loading