Previous Thread
Next Thread
Print Thread
Rating: 5
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Ok once again this seems to be working. I wasn't able to do a lot of testing on my test site because it's not posted to very often. LoL

This modification will allow a registered user to "Mark All Read" all new threads/posts or just one board at a time by clicking on the lighted light bulb. (the yellow one)

The instructions are inside the markallread.6.1.php file. Download the zip and view with your favorite editor, change the affected files and upload them and the markallread.6.1.php script to your threads and/or template directories.

I think that's it. Enjoy
Attachments
48993-markallread.6.1.zip (0 Bytes, 33 downloads)

Sponsored Links
Joined: Mar 2002
Posts: 305
Enthusiast
Enthusiast
Offline
Joined: Mar 2002
Posts: 305
Thank you, it seems to work just fine!


[:"red"]Lisa[/]
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Your Welcome

That's good to hear that it seems to be working elsewhere... lol

Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
I just noticed a glitch on my test site. A few of the forums had every post/reply marked as new in the forum list when they shouldn't have. Clicking on the "Mark All Read" fixed it though. I think I may have a bug or two in the individual marking of the boards. I'll have to look through everything and see what may be the cause.

sjsaunders #218149 06/08/2002 8:30 AM
Joined: Jan 2001
Posts: 374
Enthusiast
Enthusiast
Offline
Joined: Jan 2001
Posts: 374
Cool!
also something else:
on NS4.7/MAc the href javascript: calls do not work.
That means the hack does not get triggered at all,
and will not work.

I like the workaround for it used in the instant-code THREADS, using the call to a fake function x and then a oncick event to the right thing instead.


Sponsored Links
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
I'll make them changes for this next release. I still need to make sure I got the individual board clearing correct.

Joined: Jan 2001
Posts: 374
Enthusiast
Enthusiast
Offline
Joined: Jan 2001
Posts: 374
Thank you.
Very much appreciated.
Yes, the individual board clearing didn't work here 100%.
But I am sure this is a matter of days

Joined: Jan 2001
Posts: 374
Enthusiast
Enthusiast
Offline
Joined: Jan 2001
Posts: 374
Hi, I played a little to make your hack language-file aware. Hope I didn't mess up code

In the ubbt_registerednav, I changed your code like this:
code:
| <script language="javascript" type="text/javascript"><!--
function MarkAllRead(board,title){
if(board) {
document.markall.oneboard.value=board;
if (confirm("{$ubbt_lang['MARKALL_READ2']} "+title+" {$ubbt_lang['MARKALL_READ3']} {$ubbt_lang['MARKALL_READ4']}")) {
document.markall.submit();
}
}
else {
if (confirm("{$ubbt_lang['MARKALL_READ1']} {$ubbt_lang['MARKALL_READ4']}")) {
if (confirm('{$ubbt_lang['MARKALL_READ9']}')) {
document.markall.submit();
}
}
}
}
// -->
</script>



and added code in the Generic language files:
code:
// Hack MarkAllRead (for Javascript Alerts, so: no " or ' or & ):
$ubbt_lang['MARKALL_READ1'] = "You are about to mark all posts/threads as read.";
$ubbt_lang['MARKALL_READ2'] = "All threads/posts for";
$ubbt_lang['MARKALL_READ3'] = "will be marked as read.";
$ubbt_lang['MARKALL_READ4'] = "\\nThis action can not be reversed! \\n \\nPress OK to continue...";
$ubbt_lang['MARKALL_READ9'] = "R E A L L Y ???\\n\\nReset ALL posts as READ????";


Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Thanks Carl,

It's a good thing to get the text moved into the language files.

Are you having any problems with the individual board marking? As far as I can tell there shouldn't be. This was just a concern I had while making it. I'm not big on cookies. LoL

Joined: Jan 2001
Posts: 374
Enthusiast
Enthusiast
Offline
Joined: Jan 2001
Posts: 374
Yes, on my board I have cases, where, when I hit the bulb to markread an individual board, All messages are set as NEW (on all boards!) instead.

Could be that something's wrong with my hack implementation (and language file inclusion), and not with your original code. - That's why I am wondering whether anybody else experienced this with the hack too.

Sponsored Links
Joined: Mar 2002
Posts: 305
Enthusiast
Enthusiast
Offline
Joined: Mar 2002
Posts: 305
Dave, just wanted to say we've been using this for several weeks now on our testboard (only about 10 users), and we haven't had a single problem. It's worked perfectly every time. Thank you!

I attached the post I made to try to explain it to our members. It probably has a lot more detail than most other boards would want, but anyone is free to use it.
Attachments
52198-markallread-description.txt (0 Bytes, 35 downloads)


[:"red"]Lisa[/]
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Thanks Lisa

It's nice to know that this got a lengthy testing with no problems being evident.

Joined: Aug 2002
Posts: 32
User
User
Offline
Joined: Aug 2002
Posts: 32
Just installed this one in Threads 6.1 release, button is there, it works, i press OK, but no posts gets set to read.

Gone trought the instructions twice and have done all it ask for...

Does everybody get it to work in 6.1 without trouble?


Organizer
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
This hasn't been tested on UBB.threads 6.1 as of yet. The name of the file should never have been 6.1 as it was originally 6.0 but needed fixes to work with UBB.threads 6.0 and once I made the changes I changed the file to 6.1 to reflect the changes.

Has anyone been able to make this one work on their board?

Joined: Aug 2002
Posts: 32
User
User
Offline
Joined: Aug 2002
Posts: 32
Okay, but this thredsdev forum is running 6.1 and it does work here I think at least

Hope you can figure out what changes thats needed, it's a nice feature


Organizer
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Here we are using "Mark All Read" and not "Mark All or One Read". There didn't seem to be any changes needed for "Mark All Read" as it worked with 6.1 right away.

Joined: Aug 2002
Posts: 32
User
User
Offline
Joined: Aug 2002
Posts: 32
Dear JustDave, would it be possible to have this for 6.2. I hate not having the option to mark only one forum, marking all many times ok, but far from always...

*hopefully waiting*


Organizer
Joined: Jun 2001
Posts: 3,273
That 70's Guy
That 70's Guy
Offline
Joined: Jun 2001
Posts: 3,273
Not sure when I can do this but it's been on my list for a while. Perhaps sometime during the week (next week) I can get to this.


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)