D
D
Dmax992020-01-02 21:05:26
HTML
Dmax99, 2020-01-02 21:05:26

How to clear textarea from heml tags?

Hello!
Can you please tell me how to clear textarea from heml tags in CKeditor 4?

<div id="content-11">
  <div class="texttransl">
    <div class="row">
      <div class="input-field col s12">
        <textarea name="news_heading_ru" id="news_heading_ru" class="materialize-textarea" rows="16"><?php echo $data['news_heading_ru']; ?></textarea>
        <script type="text/javascript" src="assets/js/ckeditor/ckeditor.js"></script>
        <script>CKEDITOR.replace( 'news_heading_ru', { enterMode: Number(2),} );</script>
      </div>
    </div>
  </div>
</div>

I would disable all tags in the config, but in another textarea these tags are needed. And how to disable it in this - I don’t understand, I searched in Google, but everything is even ...
Maybe there is a solution ??
Thank you very much in advance!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
mletov, 2020-01-02
@Dmax99

The first thing that comes to mind:
- Keep 2 copies of ckeditor in the project with different configs and, depending on the url, connect the right
one - Check the url in the body of the config (it's like js, if my memory serves me right) and push different settings
Maybe there are more a competent option, this is so, the most obvious
UPDATE:
Google, it seems like the path to the config can be written there during initialization
https://ckeditor.com/docs/ckeditor4/latest/guide/d...
Then it's even easier, check the url and substitute the path to the desired configuration

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question