vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Post Redirection Message (PRM) Hack - Custom "postthanks" messages per forum! (https://vborg.vbsupport.ru/showthread.php?t=44557)

N!ck 10-12-2002 10:00 PM

Post Redirection Message (PRM) Hack - Custom "postthanks" messages per forum!
 
This hack replaces the message you see after posting a new thread or reply ( the "Thanks for posting! You will now be taken to..." message). You can even set multiple messages if you want to use different messages for each forum!

Screenshots will follow!

++++++++++++++++++++++
Version 1.2 - 10/30/02
++++++++++++++++++++++

I'd really like to thank Xenon - he helped me immensely in the debugging process!

Download: click here

Upgrading to 1.2: click here for instructions

Enjoy!

-Nick

N!ck 10-13-2002 12:26 AM

screenshot 1: admin cp

N!ck 10-13-2002 12:28 AM

screenshot 2: admin cp (edit forum)

N!ck 10-13-2002 12:28 AM

screenshot 3: after posting

Matt87 10-13-2002 01:02 AM

VERY Nice... Good Job, A definate install :p

N!ck 10-13-2002 01:14 AM

:D

Velocd 10-13-2002 01:30 AM

Hey nifty idea, *kicks install* ;)

N!ck 10-13-2002 01:36 AM

let me know if anything isn't working quite right...i had to revise the instructions a couple times, even after Xenon worked on them.

ZiRu$ 10-13-2002 02:11 AM

I'd rather if it would say RETURN TO FORUM, RETURN TO MESSAGE, RETURN TO INDEX

Smoothie 10-13-2002 02:19 AM

Removed my re-directs long ago...

N!ck 10-13-2002 02:43 AM

oh.

Matt87 10-13-2002 03:12 AM

My forums are screwed right now, but once I fix them... Yes, I'll install :p

Dean C 10-13-2002 10:57 AM

lol cool hack ! :D

- miSt

FleaBag 10-13-2002 02:12 PM

How can I edit the actual HTML of that redirection page?

N!ck 10-13-2002 02:24 PM

if you want to edit the whole page, you'd have to edit the standardredirect template. otherwise, if you want to edit only the html in the box where the message is, you can insert it in your post redirection message.

Erwin 10-13-2002 09:24 PM

Quote:

Originally posted by Smoothie
Removed my re-directs long ago...
Ditto. :)

N!ck 10-13-2002 11:29 PM

wow.

Bison 10-14-2002 01:25 AM

Why?

N!ck 10-14-2002 02:37 AM

why what?

Bison 10-14-2002 03:28 AM

Would anyone remove the redirector code?

And Nick, for the life of me, I couldn't find this code in newthread.php:

PHP Code:

 $bbuserinfo['username'] = htmlspecialchars($bbuserinfo['username']);
        }
      } 


N!ck 10-14-2002 03:32 AM

that code should be right above:

PHP Code:

      // redirect
      
if ($postpoll) {
        
$goto="poll.php?s=$session[sessionhash]&threadid=$threadid&polloptions=".intval($polloptions);
      } elseif (
$visible) {
        
$goto="showthread.php?s=$session[sessionhash]&threadid=$threadid";
      } else {
        
$goto="forumdisplay.php?s=$session[sessionhash]&forumid=$forumid";
      } 

if you still can't find it, let me know.

____________________________

on the other note, i guess people might remove the redirects to cut down on bandwidth or something...i'm as mystified as you are though ;)

Bison 10-14-2002 03:41 AM

Couldn't find it ... could I just place this

PHP Code:

$newforuminfo=$DB_site->query_first("SELECT * FROM postthanks WHERE postthanksid = '".$foruminfo[postthanksid]."'"); 

above the code you mention above the //Redirect comment?

N!ck 10-14-2002 04:04 AM

mmm...you could try it; it won't hurt anything. i suspect maybe you've modified that part of the code before... :)

if it doesn't work, let me know what version you have.

thedvs 10-14-2002 11:54 AM

everything worked fine until I came to...

Find:
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++
moderateattach)
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++
Replace it with:
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++
moderateattach,postthanksid)
++++++++++++++++++++++++++++++++++++++++++++++++++ +++++++++++++++++++++

etc, in forum.php

Using 2.2.8

N!ck 10-14-2002 01:00 PM

in wordpad, search for ",moderateattach" (w/o quotes) and try to find it. you might have made a modification to that part of the code.

thedvs 10-14-2002 02:44 PM

ok it all worked! thank you for a brilliant hack! just what i was looking for!

N!ck 10-14-2002 10:08 PM

i'm happy for you, and you are very welcome. :)

ZiRu$ 10-27-2002 05:17 PM

Quote:

Originally posted by ZiRu$
I'd rather if it would say RETURN TO FORUM, RETURN TO MESSAGE, RETURN TO INDEX
my bad i didnt realize i can do this for EVERY forum. I will install :) good work

BigJohnson 10-27-2002 10:27 PM

Can someone help me. I only want the same redirection message for a reply and a new thread for the certain forum. How we would go by changing this? All i need is it to change the new thread redirection.

N!ck 10-28-2002 01:37 AM

Quote:

Originally posted by BigJohnson
Can someone help me. I only want the same redirection message for a reply and a new thread for the certain forum. How we would go by changing this? All i need is it to change the new thread redirection.
it's already worked into the next version, which will be released within 48 hours.

Visionray 10-29-2002 12:26 AM

um, you can do this exact same thing by going into your control panel and editing the redirect templates.

N!ck 10-30-2002 01:44 AM

no you can't

Visionray 10-30-2002 10:50 AM

Oh, well I was mistaken, I see this hack is for different messages in multiple forums. I was talking about changing the message for all news posts in all the forums, which you can do in your admin pc with a template edit.

N!ck 10-30-2002 08:29 PM

I've cautiously removed this from BETA and also added the ability to change messages depending on whether a new thread or a new reply is being posted.

To upgrade, I'd recommend uninstalling and starting over, BUT you can just update by redoing steps 5-7 in readme-prm.txt, uploading prm.php to your admin folder (overwrite old one), issuing the following SQL query, and running the install script again.

[sql]DROP TABLE postthanks;
ALTER TABLE forum DROP postthanksid;[/sql]

The new version is attached; enjoy!

Chris M 10-30-2002 08:43 PM

Nice:)

Satan

N!ck 10-30-2002 10:53 PM

thanks :)

Boofo 01-08-2003 09:33 AM

Quote:

Originally posted by Erwin


Ditto. :)

How do you do that. Is there a way to globally turn them off?


All times are GMT. The time now is 01:01 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01176 seconds
  • Memory Usage 1,783KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (37)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete