allow dashes in block IDs

This commit is contained in:
Shish 2019-12-01 23:41:10 +00:00
parent 18be03997a
commit 3e408c0f28

View file

@ -63,7 +63,7 @@ class Block
if (is_null($id)) {
$id = (empty($header) ? md5($body) : $header) . $section;
}
$this->id = preg_replace('/[^\w]/', '', str_replace(' ', '_', $id));
$this->id = preg_replace('/[^\w-]/', '', str_replace(' ', '_', $id));
}
/**