Previous Thread
Next Thread
Print Thread
Hop To
Bug with PDF view
#261680 09/30/2018 2:54 PM
Joined: Jun 2006
Posts: 293
Enthusiast
OP Offline
Enthusiast
Joined: Jun 2006
Posts: 293
Hi All,

Have just had the latest version installed and there appears to be a issue with guest, users and Registered Members.

  • Users Permissions
    They have permission to view all post areas but are not able to download, post, PM or view attachments.
  • Registered Members (subscription)
    They have access to all areas of the forum and are able to download, post, PM and view all atachments.

The issue since the install of the latest (7.6.2) version is that all guest, Users and Registered Members can view all pdf files and use the pop-out to view and print. Note that Guest and Users are unable to download the pdf files.

Any assistance on how to correct this issued would be appreciated as the subscriptions help pay for hosting and updates to the forum.

Re: Bug with PDF view
Outdoorking #261681 09/30/2018 3:01 PM
Joined: Jun 2006
Posts: 15,956
Likes: 31
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Jun 2006
Posts: 15,956
Likes: 31
Please explain further, as your original message in PT indicated just an issue with Guests being able to view PDFs inline when their permission did not allow for it.

From what it sounds like in your post, you're having more issues than just with PDFs being allowed to be viewed by users without the proper permission.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Bug with PDF view
Outdoorking #261682 09/30/2018 3:10 PM
Joined: Jun 2006
Posts: 15,956
Likes: 31
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Jun 2006
Posts: 15,956
Likes: 31
Regarding the print page, it's simply a cleaned up/optimized version of the post template which is more friendly for printing; there should be a listing of attachments (if applicable) shown with a full link to where the file exists (clicking on these links should send one through the permission matrix for the files). The print template hasn't been updated since v7.6.0.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Bug with PDF view
Outdoorking #261683 09/30/2018 3:20 PM
Joined: Dec 2003
Posts: 6,183
Likes: 28
Online Yawn
Joined: Dec 2003
Posts: 6,183
Likes: 28
Going to need a url for a offending post attachment..


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Re: Bug with PDF view
Ruben #261684 09/30/2018 3:25 PM
Joined: Apr 2004
Posts: 1,718
Likes: 63
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Apr 2004
Posts: 1,718
Likes: 63
Originally Posted by Ruben
Going to need a url for a offending post attachment..

https://www.outdoorking.com/forum/u...en-30-bowling-green-mower.html#Post92964

The issue he is having, is that since PDF files can now be displayed inline, they are not respecting the group permissions setting (just the inline pdf display). But all the other permissions are being respected exactly the same way they were in 761 and prior.


Current developer of UBB.threads PHP Forum Software // 7.7.4 released!
isaac @ id242.com // my forum @ CelicaHobby.com
Re: Bug with PDF view
Outdoorking #261685 09/30/2018 3:35 PM
Joined: Dec 2003
Posts: 6,183
Likes: 28
Online Yawn
Joined: Dec 2003
Posts: 6,183
Likes: 28
AHH!
I see said the blind man.
This is my first attempt to view this feature.


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Re: Bug with PDF view
Outdoorking #261686 09/30/2018 3:50 PM
Joined: Dec 2003
Posts: 6,183
Likes: 28
Online Yawn
Joined: Dec 2003
Posts: 6,183
Likes: 28
I guess I need to install 7.6.2.
Maybe there is a new permission for those files.
I see several inline images (JPG) that appears in the post so why not PDF should appear..
If it is just part of the allowed file formats.
How would you segregate them?

Will this be a bug?
Refresh?
Future release?
Mod till future release?


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Re: Bug with PDF view
Outdoorking #261687 09/30/2018 3:54 PM
Joined: Jun 2006
Posts: 15,956
Likes: 31
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Jun 2006
Posts: 15,956
Likes: 31
Well, we're going to stay on topic and see why the permission system is allowing guests to see the attachment and patch it in the next release; but we'll need to find the cause first.

It's likely something minor such as a misplacement of a variable in the script.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Bug with PDF view
Outdoorking #261688 09/30/2018 4:27 PM
Joined: Dec 2003
Posts: 6,183
Likes: 28
Online Yawn
Joined: Dec 2003
Posts: 6,183
Likes: 28
I think I am on topic.
what I am saying is if you view the post as a guest that isaac posted.
There are many jpg files that appear inline. As well as the pdf attachment.
So what would be the difference if it were a txt file?
In 7.6.0 there is not a permission to not allow viewing attachments, just downloading them.
So if a guest has view rights to a forum then they can view everything. Including attachments.
All you can do is disable downloads.

Unless there is a net new permission in 7.6.2.?????


Does not give a clue that the pdf is following the same permission as the normal attachments.


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Re: Bug with PDF view
Outdoorking #261689 09/30/2018 4:28 PM
Joined: Jun 2006
Posts: 15,956
Likes: 31
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Jun 2006
Posts: 15,956
Likes: 31
Embedding images via the [img] tag is not an attachment. This issue only affects PDF files which are attached to a post.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Bug with PDF view
Outdoorking #261690 09/30/2018 5:06 PM
Joined: Apr 2004
Posts: 1,718
Likes: 63
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Apr 2004
Posts: 1,718
Likes: 63
This permissions correction will be in the next release version of UBB.threads. If anyone needs this fixed right now and cannot wait until the next release, the fix is simple:

in /scripts/showflat.inc.php
FIND
Code
if ($ext == "pdf") {

REPLACE WITH
Code
if ($ext == "pdf" && $userob->check_access("forum", "CAN_DOWNLOAD", $topic_info['FORUM_ID'])) {

thats all.

Outdoorking - thank you for this thumbsup


Attached Files 20180930_14-01-27.PNG20180930_14-01-13.PNG

Current developer of UBB.threads PHP Forum Software // 7.7.4 released!
isaac @ id242.com // my forum @ CelicaHobby.com
Re: Bug with PDF view
Outdoorking #261691 09/30/2018 5:07 PM
Joined: Jun 2006
Posts: 15,956
Likes: 31
UBB.threads Developer
Offline
UBB.threads Developer
Joined: Jun 2006
Posts: 15,956
Likes: 31
Bruce, I updated your forum with the posted fix.


I am a Web Development Contractor, I do not work for UBBCentral. I have provided free User to User Support since the beginning of these support forums.
Do you need Forum Install or Upgrade Services?
Forums: A Gardeners Forum, Scouters World
UBB.threads: UBBWiki, UBB Styles, UBB.Sitemaps
Longtime Supporter & Resident Post-A-Holic
VNC Web Services: Code Modifications, Upgrades, Styling, Coding Services, Disaster Recovery, and more!
Re: Bug with PDF view
Gizmo #261692 09/30/2018 5:16 PM
Joined: Dec 2003
Posts: 6,183
Likes: 28
Online Yawn
Joined: Dec 2003
Posts: 6,183
Likes: 28
Originally Posted by Gizmo
Embedding images via the [img] tag is not an attachment.
I guess Gizmo is to busy to read the complete post before he replies.
Inline images was just part of my post.
But anyway isaac answered the question correctly.
It is the "can download attachment permission" that is the issue.

I never knew that permission included viewing..
I guess it makes sense. If you open the attachment then you are actually downloading it.

Thanks Isaac for the proper answer and a interim fix.


Blue Man Group
There is no such thing as stupid questions. Just stupid answers
Re: Bug with PDF view
isaac #261693 10/01/2018 12:15 AM
Joined: Jun 2006
Posts: 293
Enthusiast
OP Offline
Enthusiast
Joined: Jun 2006
Posts: 293
Originally Posted by isaac
This permissions correction will be in the next release version of UBB.threads. If anyone needs this fixed right now and cannot wait until the next release, the fix is simple:

in /scripts/showflat.inc.php
FIND
Code
if ($ext == "pdf") {

REPLACE WITH
Code
if ($ext == "pdf" && $userob->check_access("forum", "CAN_DOWNLOAD", $topic_info['FORUM_ID'])) {

thats all.

Outdoorking - thank you for this thumbsup

Thank you very much for the quick fix it is really appreciated.


Link Copied to Clipboard
ShoutChat Box
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Recent Topics
Disaster!!! Files became empty.. Please advise.
by Morgan - 07/27/2020 2:38 PM
Unable to Update Censor List
by BOTCuser - 07/22/2020 9:15 AM
7.7.4 error on rebuilders
by Ruben - 07/21/2020 3:06 PM
[STOCK] UBB.threads Group Image Pack
by isaac - 07/19/2020 9:03 PM
Who's Online Now
2 members (Ruben, 1 invisible), 59 guests, and 70 robots.
Key: Admin, Global Mod, Mod
Random Gallery Image
Latest Gallery Images
3D Creations
3D Creations
by JAISP, December 30
Artistic structures
Artistic structures
by isaac, August 29
Stones
Stones
by isaac, August 19
Amusing Terain Scenics
Amusing Terain Scenics
by isaac, August 19
Sky places
Sky places
by isaac, August 19
Powered by UBB.threads™ PHP Forum Software 7.7.4