Planet Hanyu Posted February 10, 2019 Posted February 10, 2019 Hi, Sometimes our users post too much content in one post and it doesn't load on some old browsers. We'd like a button that can "unembed" all of your content in your post, programmatically. A button that can just run all the content of your post through, say, JavaScript or some other scripting language that can replace all the oEmbed links with normal links, that would be perfect. It doesn't even need to do exactly that, I can write the JavaScript myself, but I just don't know how to ... add such a button to the editor? I would be willing to pay a developer to develop something like this, if it's not currently available. It's quite important for our site. So if nothing is available, I would love to know the proper channel to request this if possible 🙂 Thanks! PH
opentype Posted February 10, 2019 Posted February 10, 2019 I doubt there is an easy way to achieve this, since the original links aren’t saved. It’s just a block of HTML saved in the database. One would probably have to code a separate detection algorithm for every external source to turn it back into a link.
Planet Hanyu Posted February 10, 2019 Author Posted February 10, 2019 8 hours ago, opentype said: I doubt there is an easy way to achieve this, since the original links aren’t saved. It’s just a block of HTML saved in the database. One would probably have to code a separate detection algorithm for every external source to turn it back into a link. I have a code that does this in Python, but I can't ask the users to use it every time. I just want a button that just runs any type of scripting language on the entire post content, is that possible?
Planet Hanyu Posted February 19, 2019 Author Posted February 19, 2019 On 2/10/2019 at 10:32 AM, opentype said: I doubt there is an easy way to achieve this, since the original links aren’t saved. It’s just a block of HTML saved in the database. One would probably have to code a separate detection algorithm for every external source to turn it back into a link. Bump, I'd be interested in how at all to process the HTML. I already do it in Python but i have to copy and paste the source and run it with Python code. Our users don't have access to the source so they can't do that. Any way we could do it with a button?
Recommended Posts
Archived
This topic is now archived and is closed to further replies.