Page Index Toggle Pages: [1] 2 
Topic Tools
Hot Topic (More than 10 Replies) Mark as read (Read 1,998 times)
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Mark as read
Dec 10th, 2012 at 1:51pm
Post Tools
Version 2.4

There are a few members that this feature doesn't work (It works fine on my systems).

I had them:
Reboot the computer
Clear their cache
Clear their cookies
Update Java

None of which seems to work

Any ideas?
  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #1 - Dec 10th, 2012 at 10:41pm
Post Tools
Update their browser? (YaBB doesn't use java, but it does use javascript (different language)) and it's just possible they're using browsers that don't support all the javascript features (even though 2.4 is ancient by web standards.)
  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
JonB
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 4,025
Location: Land of the Blazing Sun!

YaBB 2.6.1
Re: Mark as read
Reply #2 - Dec 11th, 2012 at 1:15pm
Post Tools
I'd see what they have in common.

Browser choice?

Use of SmartPhone to access?

Use of the 'back arrow' to navigate?


Good Luck
Wink

  

I find your lack of faith disturbing.
Back to top
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #3 - Dec 11th, 2012 at 2:10pm
Post Tools
Most of them have tried a combination of Firefox, Chrome and Explorer. All use some version of windows and are on a desktop or laptop.

this is what one person sent me
Quote:
FireFox 17.0.1, from addon's list:

Java Deployment Toolkit 6.0.290.11 and 6.0.310.5 are enabled.
Java Platform SE U29 and U31 are disabled.

Windows XP service pack 3:

J2SE Runtime Environment 5.0 update 10, 11
Java 6 update 2, 3, 31


Another member sent me this
Quote:


When I click on the top link I get this error
Quote:
Untrapped Error :
Died at ./Sources/MessageIndex.pl line 829.

  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #4 - Dec 11th, 2012 at 3:07pm
Post Tools
And I'm betting that error is part of the problem. (The error is referring to the MarkRead sub in MessageIndex.pl - something is either wrong in the sub routine or the variables being set to it are bad. - and based on what your member sent, it's the variables being sent to the javascript.)

Have you added any mods recently?
  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #5 - Dec 11th, 2012 at 6:51pm
Post Tools
Its been over a year (maybe more) that I've added a new mod.

But wouldn't that effect everyone if that was the case? It works for many of the members including me.

Code (Perl)
Select All
sub MarkRead { # Mark all threads in this board as read.
	# Load the log file
	&getlog;

	# Look for any threads marked unread in the current board and remove them
	fopen(BRDTXT, "$boardsdir/$currentboard.txt") || &fatal_error("cannot_open","$boardsdir/$currentboard.txt", 1);
	my @threadlist = map {/^(\d+)\|/} <BRDTXT>;
	fclose(BRDTXT);

	# Loop through @threadlist and delete the corresponding item from %yyuserlog
	foreach (@threadlist) { delete $yyuserlog{"$_--unread"}; }

	# Write it out
	&dumplog("$currentboard--mark");

	if($INFO{'oldmarkread'}) {
		&redirectinternal;
	}
	$elenable = 0;
	die ""; # This is here only to avoid server error log entries!
}
 



  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #6 - Dec 11th, 2012 at 8:30pm
Post Tools
The actual error appears to be something with the javascript that's sending the information to the MarkRead sub routine.
Code
Select All
javascript:MarkAllAsRead('http://www.woodturnersresource.com/cgi-bin/yabb2/YaBB.pl?board=tips&&action=mark...','http://www.woodturnersresource.com/yabb2files/Templates/Forum/woody')  



OR that double ampersand. If that's part of the board name it could be causing issues - unless the coding has changed between 2.4 and 2.5 it should be a semi-colon separating the fields.

  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #7 - Dec 11th, 2012 at 9:28pm
Post Tools
so if its javascript how is that fixed?


Dandello wrote on Dec 11th, 2012 at 8:30pm:
OR that double ampersand. If that's part of the board name it could be causing issues

The double ampersand is not a part of the board name
  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #8 - Dec 11th, 2012 at 10:29pm
Post Tools
That's a good question. The code didn't change between 2.4 and 2.5
it's:
Code
Select All
		$markalllink = qq~$menusep<a href="javascript:MarkAllAsRead('$scripturl?board=$INFO{'board'};action=markasread','$imagesdir')">$img{'markboardread'}</a>~;
 



Which indicate something in "$INFO{'board'}" as the culprit.

Note that in the javascript you were sent, there are two ampersands and no semi-colon. Which kind of tells me we're looking for an ampersand - in fact we're looking at something like '&amp'  or '&&amp' So open up in a text editor './Boards/forum.control' and './Boards/forum.master' - and make sure there are no errant ampersands, or partial codes for one, in there.

Edited:
And I've been playing around with ampersands in Board names and haven't been able to reproduce this problem.
« Last Edit: Dec 11th, 2012 at 10:37pm by Dandello »  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #9 - Dec 13th, 2012 at 7:12pm
Post Tools
Code
Select All
$board{'tips'} = qq~Tips &amp; Techniques||~; 



There it is!

Let me inform the membership and see if that fixes the problem and I'll get back

Thanks
  
Back to top
 
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #10 - Dec 14th, 2012 at 6:06pm
Post Tools
Unfortunately that wasn't the answer.

One person wrote
Quote:
nothing.  just a white bar, about 1/16" high by 4" long.


I have no idea what he means. I asked him to post an image so I can see what he is talking about
  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #11 - Dec 14th, 2012 at 8:35pm
Post Tools
It the problem only happening with the Tips board is involved in being marked as read? Or are other boards throwing similar errors?
  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #12 - Dec 14th, 2012 at 11:01pm
Post Tools
Yes, it happens on all the boards
  
Back to top
 
IP Logged
 
Dandello
YaBB Administrator
YaBB Next Team
Operations Team
Beta Testers
Support Team
*****
Offline



Posts: 2,467
Location: Earth

YaBB 2.6.1
Re: Mark as read
Reply #13 - Dec 15th, 2012 at 12:23am
Post Tools
You're going to have to do some sleuthing into the actual code.

download copies of Sources/BoardIndex.pl and MessageIndex.pl and open them in a good text-editor (not a word processor). Look for the string 'MarkAllAsRead' and inspect the lines you find with it (should be 1 in MessageIndex.pl and 2 in BoardIndex.pl.)

All three lines should resemble the code posted earlier (they won't be exactly alike but you're looking for things that shouldn't be there, like ampersands.)

The problem, though, is that apparently not everybody is getting this error, which makes it harder to track down.
  

If you only have one solution to a problem you're not trying hard enough!
Back to top
WWW  
IP Logged
 
------
Senior Member
Beta Testers
****
Offline



Posts: 528
Re: Mark as read
Reply #14 - Dec 15th, 2012 at 12:56am
Post Tools
From my amateur eye they look ok

From BoardIndex.pl
Code (Perl)
Select All
		if ($INFO{'catselect'} eq '') {
			if ($colbutton) { $col_vis = ""; }
			else { $col_vis = " style='display:none;'"; }
			if (${$uid.$username}{'cathide'}) { $exp_vis = ""; }
			else { $exp_vis = " style='display:none;'"; }

			$expandlink = qq~<span id="expandall" $exp_vis><a href="javascript:Collapse_All('$scripturl?action=collapse_all;status=1',1,'$imagesdir','$boardindex_exptxt{'2'}')">$img{'expand'}</a>$menusep</span>~;
			$collapselink = qq~<span id="collapseall" $col_vis><a href="javascript:Collapse_All('$scripturl?action=collapse_all;status=0',0,'$imagesdir','$boardindex_exptxt{'1'}')">$img{'collapse'}</a>$menusep</span>~;
			$markalllink = qq~<a href="javascript:MarkAllAsRead('$scripturl?action=markallasread','$imagesdir')">$img{'markallread'}</a>~;

		} else {
			$markalllink  = qq~<a href="javascript:MarkAllAsRead('$scripturl?action=markallasread;cat=$INFO{'catselect'}','$imagesdir')">$img{'markallread'}</a>~;
			$collapselink = '';
			$expandlink   = '';
		}
 



From MessageIndex.pl
Code (Perl)
Select All
	if (!$iamguest) {
		$markalllink = qq~$menusep<a href="javascript:MarkAllAsRead('$scripturl?board=$INFO{'board'};action=markasread','$imagesdir')">$img{'markboardread'}</a>~;
		$notify_board = qq~$menusep<a href="$scripturl?action=boardnotify;board=$INFO{'board'}">$img{'notify'}</a>~;
 

  
Back to top
 
IP Logged
 
Page Index Toggle Pages: [1] 2 
Topic Tools