Add 'Remove HTML block'

chris 2021-05-17 15:58:56 +02:00
parent e52dd520b8
commit f64e185550
1 changed files with 24 additions and 0 deletions

24
Remove-HTML-block.md Normal file

@ -0,0 +1,24 @@
Users can paste text into the Omeka HTML block. This is undesirable because html style and classes are included in the html.
We de not want unexpected formats.
For this reason we have developed the Markdown text module. Markdown allows basic HTML formatting without extra unwanted text formatting.
But we also want to remove the HTML block so users cannot include it in their pages.
You need to copy the page template from the omeka core into the arcHIVE theme.
From the omeka core copy `./application/view/omeka/site-admin/page/edit.phtml`
And paste it into the arcHIVE theme `./view/omeka/site-admin/page/edit.phtml`
Then edit the new file, adding the line `<?php if ($layout == "html") { continue; } ?>`
```
<?php foreach ($this->blockLayout()->getLayouts() as $layout): ?>
-->> <?php if ($layout == "html") { continue; } ?>
<button type="button" value="<?php echo $escape($layout); ?>" class="option">
<?php echo $escape($translate($this->blockLayout()->getLayoutLabel($layout))); ?>
</button>
<?php endforeach; ?>
```