Advertisement

issue with embedding pdf file.

Need help with the Administration of your Joomla! 5.x site? This is the spot for you.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10
Post Reply
sergec68
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Fri Nov 01, 2024 2:55 pm

issue with embedding pdf file.

Post by sergec68 » Fri Nov 01, 2024 3:11 pm

Hello,

I have just registered to the forum site.

I've got an issue trying to embed PDF files on my local website.

I use the custom module and I select CMS media, I then choose the file with the embed option. the pdf is displayed, however when I save the module, it disappears. as seen on the video.
https://www.dropbox.com/scl/fi/4m5jun79 ... 4asor&dl=0

Advertisement
User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 44758
Joined: Sat Apr 05, 2008 9:58 pm

Re: issue with embedding pdf file.

Post by Webdongle » Fri Nov 01, 2024 3:18 pm

Check your editor settings. Tinymce plugin has options to allow/disallow certain code. JCE editor has similar in its component
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".

sergec68
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Fri Nov 01, 2024 2:55 pm

Re: issue with embedding pdf file.

Post by sergec68 » Sun Nov 03, 2024 7:49 pm

This is the code I use for embedding a pdf:

<p><object data="images/pdf/august_newsletter.pdf" type="application/pdf" width=“%” height=“500”>
You don't have a pdf plugin, but you can <a download="" images/pdf/august_newsletter.pdf"> download the pdf file.</a></object> </p>

so what type of code do I need to allow in Tinymce.

tthe thing is that I add the code in the code mode of Tinymmce But when I save, the code disappears.

https://www.dropbox.com/scl/fi/wawk4l4f ... 2lsiz&dl=0

User avatar
AMurray
Joomla! Master
Joomla! Master
Posts: 10345
Joined: Sat Feb 13, 2010 7:35 am
Location: Australia

Re: issue with embedding pdf file.

Post by AMurray » Sun Nov 03, 2024 9:20 pm

That's Joomla's security settings at work. It's removing "suspect" tags or content. Check your settings as @webdongle says.

I think the <object> tag is not allowed by default, so you have to allow it under the Global Configuration / Text Filtering options.

Text Filters - Documentation:
https://docs.joomla.org/Help4.x:Site_Gl ... xt_Filters

Also check:
https://www.tiny.cloud/docs/tinymce/lat ... r-content/
Regards - A Murray
General Support Moderator

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 44758
Joined: Sat Apr 05, 2008 9:58 pm

Re: issue with embedding pdf file.

Post by Webdongle » Sun Nov 03, 2024 9:34 pm

Plugins >>> Tinymce ... Prohibited Elements (field) ... remove 'script,'
Be careful who you allow to to the 'edit set'
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".

sergec68
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Fri Nov 01, 2024 2:55 pm

Re: issue with embedding pdf file.

Post by sergec68 » Sun Nov 03, 2024 10:35 pm

Thanks.

User avatar
Webdongle
Joomla! Master
Joomla! Master
Posts: 44758
Joined: Sat Apr 05, 2008 9:58 pm

Re: issue with embedding pdf file.

Post by Webdongle » Mon Nov 04, 2024 12:34 am

Did that fix it?
Be careful because anyone (that's in a user group) associated with that profile can insert script into an Article they create or edit. That is any type of script. So you need to trust everyone in a User Group that is listed in that profile.
http://www.weblinksonline.co.uk/
https://www.weblinksonline.co.uk/updating-joomla.html
"When I'm right no one remembers but when I'm wrong no one forgets".

sergec68
Joomla! Apprentice
Joomla! Apprentice
Posts: 20
Joined: Fri Nov 01, 2024 2:55 pm

Re: issue with embedding pdf file.

Post by sergec68 » Mon Nov 04, 2024 1:28 am

No, after checking, it does not solve the problem.

Advertisement

Post Reply

Return to “Administration Joomla! 5.x”