Possibal 2.0.14 bug...

This is an archive of the phpBB 2.0.x support forum. Support for phpBB2 has now ended.
Forum rules
Following phpBB2's EoL, this forum is now archived for reference purposes only.
Please see the following announcement for more information: viewtopic.php?f=14&t=1385785
User avatar
PCGUY112887
Registered User
Posts: 499
Joined: Thu Apr 01, 2004 12:39 am
Location: Illinois
Contact:

Possibal 2.0.14 bug...

Post by PCGUY112887 » Sun Apr 17, 2005 2:32 am

Hey. I use HTML on my forums for <img> tags (since most of my users are used to using HTML and for other reasons). I updated to .14 and all was working well. Then I visited my forum on another comp where I wasn't automatically loged into my forums, and I noticed all images posted with <img> tags showed up as code, not images.

So I go poking around, and found this to be the problem.
FIND - Line 1052
2.0.13 Code:


if ( !$board_config['allow_html'] )
{
if ( $user_sig != '' && $userdata['user_allowhtml'] )



REPLACE WITH
2.0.14 Code:


if ( !$board_config['allow_html'] || !$userdata['user_allowhtml'])
{
if ( $user_sig != '' )

I reversed that back to what it used to be, and now it works fine. It appears that the code is saying that if the person viewing doesn't have HTML premissions, they won't have the HTML parsed. Any guests looking at a board don't have HTML premissions (my guests can't even post).

But if I login (all loged in members have HTML premission), I can see the images just fine.

And yes...
Please do not post bug reports

But where else should I post this?

tennis4u
Registered User
Posts: 272
Joined: Thu Feb 03, 2005 3:58 am

Post by tennis4u » Sun Apr 17, 2005 3:28 am

I do not have that problem.

nurhendra
Registered User
Posts: 144
Joined: Mon Feb 28, 2005 5:03 pm
Location: Jakarta

Re: Possibal 2.0.14 bug...

Post by nurhendra » Sun Apr 17, 2005 7:37 am

PCGUY112887 wrote: So I go poking around, and found this to be the problem.
FIND - Line 1052
2.0.13 Code:


if ( !$board_config['allow_html'] )
{
if ( $user_sig != '' && $userdata['user_allowhtml'] )



REPLACE WITH
2.0.14 Code:


if ( !$board_config['allow_html'] || !$userdata['user_allowhtml'])
{
if ( $user_sig != '' )

I reversed that back to what it used to be, and now it works fine. It appears that the code is saying that if the person viewing doesn't have HTML premissions, they won't have the HTML parsed. Any guests looking at a board don't have HTML premissions (my guests can't even post).


I think the idea was, if the board is not allowing HTML, then the member should not be allowed for HTML.

Translating the codes, both should be working the same way..
2.0.13:
If the board is not allowing HTML, then
{ If user signature is not empty and user is wanting HTML then
-cleanup-

2.0.14:
If the board is not allowing HTML or when the users don't want HTML then
{ If user signature is not empty then
-cleanup-

However, 2.0.13 is not restrictive, because even when the board is not allowing HTML, if the users said that they aren't using HTML, the signature didn't get cleaned up. Of course users still can put HTML in, thus bypassing the rule. Thus, the 2.0.14 fix.

If you want to allow users to have HTML, then the board should allow them. If the users don't want to use HTML, then they can choose not to.

Dukes
Registered User
Posts: 225
Joined: Sun Mar 13, 2005 10:26 am

Post by Dukes » Sun Apr 17, 2005 8:01 am

You could simply always allow HTML

User avatar
PCGUY112887
Registered User
Posts: 499
Joined: Thu Apr 01, 2004 12:39 am
Location: Illinois
Contact:

Post by PCGUY112887 » Sun Apr 17, 2005 5:16 pm

Not quite sure what you guys are saying... I DO allow HTML (aka Always Allow HTML in the admin panel is ON). Everything is fine when any user is loged on, but if a guest not loged in or anything is just browsing around, they don't see parsed HTML in posts.

If I allowed guest posting, then the guests may be able to see the HTML, but right now the only way I can get someone that isn't loged in to see parsesd HTML is to reverse the line to what was there in 2.0.13

BigRed01
Registered User
Posts: 472
Joined: Mon Jan 24, 2005 9:26 am
Location: The upper midwest

Re: Possibal 2.0.14 bug...

Post by BigRed01 » Sun Apr 17, 2005 6:00 pm

PCGUY112887 wrote: Hey. I use HTML on my forums for <img> tags (since most of my users are used to using HTML and for other reasons). I updated to .14 and all was working well. Then I visited my forum on another comp where I wasn't automatically loged into my forums, and I noticed all images posted with <img> tags showed up as code, not images.

So I go poking around, and found this to be the problem.
FIND - Line 1052
2.0.13 Code:


if ( !$board_config['allow_html'] )
{
if ( $user_sig != '' && $userdata['user_allowhtml'] )



REPLACE WITH
2.0.14 Code:


if ( !$board_config['allow_html'] || !$userdata['user_allowhtml'])
{
if ( $user_sig != '' )

I reversed that back to what it used to be, and now it works fine. It appears that the code is saying that if the person viewing doesn't have HTML premissions, they won't have the HTML parsed. Any guests looking at a board don't have HTML premissions (my guests can't even post).

But if I login (all loged in members have HTML premission), I can see the images just fine.

And yes...
Please do not post bug reports

But where else should I post this?


I'm having the exact same issue.

Paul S
Registered User
Posts: 5
Joined: Sun Feb 13, 2005 4:57 pm

Post by Paul S » Sun Apr 17, 2005 7:44 pm

I'm having the same problem and I do allow guests to post and answer. Which file contains the line of code that PCGUY pointed to so I can change it back and make the IMG tag work again?

skuipers
Registered User
Posts: 648
Joined: Sun Jan 16, 2005 9:53 pm
Location: Delft, The Netherlands

Post by skuipers » Sun Apr 17, 2005 7:47 pm

That's privmsg.php

Hopefully the development team will pick this up and investigate.

Paul S
Registered User
Posts: 5
Joined: Sun Feb 13, 2005 4:57 pm

Post by Paul S » Sun Apr 17, 2005 8:34 pm

Thanks.

I found the line and changed it as suggested, but it did not fix the problem. If I'm not logged in, the <IMG> tag doesn't work. The [img] tag does work though; it's just less versatile.

User avatar
aboyd
Registered User
Posts: 193
Joined: Mon May 10, 2004 7:30 pm
Location: USA
Contact:

Post by aboyd » Sun Apr 17, 2005 9:17 pm

My forums have the same problem. You can see it here. The signature is showing as text rather than HTML. The important note: in Admin -> Configuration, I do have HTML enabled. Is there some other place to set it?

Why is this happening? I'd try the change suggested here, but since "Paul S" said it didn't work, I'm not sure.

-Tony

User avatar
aboyd
Registered User
Posts: 193
Joined: Mon May 10, 2004 7:30 pm
Location: USA
Contact:

Post by aboyd » Sun Apr 17, 2005 9:50 pm

aboyd wrote: I'd try the change suggested here, but since "Paul S" said it didn't work, I'm not sure.

Ah. I see why it didn't work for Paul S. It wouldn't work for me either. The original post was on the right track, it just didn't go far enough. The patch file has THREE places that it updates with new HTML settings. Looking at it, I cannot explain why the old way works and the new way doesn't. But I can provide a patch. Note that 99% of phpBB users should NOT use this, because it will throw off the next official patch from phpBB. You should wait for the official patch, unless you know what you're doing.

Code: Select all

DELETED -- The proper fix is later in this thread.
That's not a very clever patch -- all I did was reverse the order of the changes, so that it undid the damage. But I have run it on my forums at outshine.com, and they are working again.

Smarter people than I will have to figure out why .14 is busted in the first place, and how to fix it (well, how to fix it better than just a rollback).
Last edited by aboyd on Mon Apr 18, 2005 1:22 pm, edited 1 time in total.

flogger12
Registered User
Posts: 14936
Joined: Tue Nov 25, 2003 2:13 am

Post by flogger12 » Sun Apr 17, 2005 10:15 pm

it is not busted, it was broke before and now it is fixed, , you will have to check with the developers as to why, one of them posted an explanation today, but I don't know the link to it.


robert

User avatar
PCGUY112887
Registered User
Posts: 499
Joined: Thu Apr 01, 2004 12:39 am
Location: Illinois
Contact:

Post by PCGUY112887 » Mon Apr 18, 2005 12:31 am

Well if it is a fix for something, it's making more apparet problems. There is no way to justify guests not being able to see your forums and posts correctelly.

The modification took place in several areas, but to fix the threads/sigs you see HTML in, it's viewtopic.php.

Please note I don't suggest doing this since your modifying and update, but I do know if you want the HTML to be parsed this is the way to make it happen.

Paul S
Registered User
Posts: 5
Joined: Sun Feb 13, 2005 4:57 pm

Post by Paul S » Mon Apr 18, 2005 2:28 am

There you go!

I replaced the line in the viewtopic.php file as identified by PCGUY and it fixed the problem. Now HTML displays properly whether I'm logged in or not.

I haven't a clue how that affects future mods, but it works for now.

User avatar
aboyd
Registered User
Posts: 193
Joined: Mon May 10, 2004 7:30 pm
Location: USA
Contact:

Post by aboyd » Mon Apr 18, 2005 2:49 am

flogger12 wrote: it is not busted, it was broke before and now it is fixed

Robert, you cannot be serious. I fully understand that there may have been a bug, and that the phpBB team tried to fix it. But do you really think it is accurate to say that the phpBB team considers it "fixed" when it leaves working forums in a non-working state?

The reason I ask this is because it is important to understand how the development team works, and evaluate if the product really is suitable. A development team that fixes something by breaking something else, and then urges people to deploy the fix on their production servers with no hint that the HTML might fail to display properly, is a team that doesn't mind putting its customers in a bind. And I don't consider a post in the forums (that neither you nor I can find) to be fair warning. If any of that is true, then I shouldn't be here, shouldn't develop mods, and should find a more courteous project to associate with.

Having said that, I suspect that the development team does not share your hardcore stance. I would not be surprised at all to learn that Acyd Burn (sp?) has already fixed the bug and is gritting his teeth at the prospect of having another patch so soon. Or maybe the patch file is accidentally different from the full version, causing some people to have a problem and some not. Or maybe there is an incompatibility with a mod that we all have in common. Any of those possibilities are at worst lazy mistakes, and more likely they are just innocent oversights. I can handle that. Every development has that kind of difficulty, and I find no fault in that. In any of those cases, I'd be willing to help -- I have 2 more boards that are still at the default 2.0.14 (I haven't tried to fix them yet), and I would be happy to try out any potential fix.

Locked

Return to “2.0.x Support Forum”