Skip to main content

Questions tagged [strip-html]

Filter by
Sorted by
Tagged with
1 vote
1 answer
27 views

Sanitise low search keywords

What's a good method for stripping HTML from our site search? I've found that it's possible to inject HTML directly into our page like this: https://website.co.uk?keywords="<svg/onload%3Dconfirm(//...
samc449's user avatar
  • 21
1 vote
2 answers
640 views

Strip line breaks, quotes, HTML out of SQL query result for CKEditor field contents (for CSV output)

I have a very simple "PHP allowed" EE template that queries the EE db and generates CSV reports from it. I need to add to one of these reports the contents of one particular channel field, which ...
Sapphireblue's user avatar
3 votes
1 answer
463 views

How can I strip <p> tags from entry content, but only if it's wrapped around a <figure>?

On occasion a <figure> tag will make it through WYGWAM with a <p> wrapped around it which breaks my layout (and is incorrect formatting anyway). Can I remove just the <p> tags that ...
Brandon Durham's user avatar
1 vote
1 answer
94 views

content cleaning

About to kick-off an 1.x to 2.x upgrade. For the most part the site is in decent shape. Unfortunately though we're dealing with some WYSIWYG fields where content that's been pasted from Word and ...
Steven Grant's user avatar
  • 2,473
2 votes
1 answer
330 views

Wygwam not stripping markup

Since Wygwam 2.3.1 it's supposed to have "Set the forcePasteAsPlainText CKEditor config setting to 'Yes' by default" (pasted from release notes). But I'm still getting a lot of junk code (inline ...
Steven's user avatar
  • 753
2 votes
1 answer
697 views

Need to upload an HTML file and display contents of DIV and nothing else

I have a case in which a client needs to be able to upload a JS and an HTML file to be displayed on a page via file upload fields. The problem is that the HTML file that is delivered to the client ...
Dan Johnson's user avatar
  • 1,110