MyBB Community Forums

Full Version: Authorization code mismatch
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
When I try to subscribe to a thread in my forum, I get the following error"

Authorization code mismatch. Are you accessing this function correctly? Please go back and try again.

Everything else works fine, it's just the subscriptions output this error.

Any ideas?
Your forumdisplay_threadlist template isn't default. Yours will probably have:

<a href="usercp2.php?action={$add_remove_subscription}subscription&amp;type=forum&amp;fid={$fid}">{$add_remove_subscription_text}</a>

Change it to this:

<a href="usercp2.php?action={$add_remove_subscription}subscription&amp;type=forum&amp;fid={$fid}&amp;my_post_key={$mybb->post_code}">{$add_remove_subscription_text}</a>
Actually just checked and I already have the second code there. Any other suggestions?

That's forum subscriptions, not thread subscriptions.

View a diff report on your showthread template to see the code that's missing.
I'm lost. Report on showthread?
ACP > Templates & Style > Templates > **expand template set** > Show Thread Templates > Options > Diff Report.

Basically you've got this in that template:

<li class="subscription_{$add_remove_subscription}"><a href="usercp2.php?action={$add_remove_subscription}subscription&amp;tid={$tid}">{$add_remove_subscription_text}</a></li>

and it needs to be this:

<li class="subscription_{$add_remove_subscription}"><a href="usercp2.php?action={$add_remove_subscription}subscription&amp;tid={$tid}&amp;my_post_key={$mybb->post_code}">{$add_remove_subscription_text}</a></li>

Viewing a diff report would have shown this.
Wow that diff report is an awesome tool, didn't even know it existed. Thanks, that fixed it!

I am experiencing the same thing on http://www.pokebeach.com/forums when I try and subscribe to threads. I already did the template changes you said to do. Is there any other area that would affect it? Otherwise I could post the whole Showthread Template.
Is your usercp_addsubscription_thread template default too??
That was the trouble. Thanks Matt.
Pages: 1 2