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)
-   -   link directly to PM in PM-Email-Notification (https://vborg.vbsupport.ru/showthread.php?t=51963)

tkeil69575 04-21-2003 10:00 PM

link directly to PM in PM-Email-Notification
 
This small hack will allow you to insert two links into the email notification that is sent out when you receive a new pm.

It add the correct PM ID so that the user can go directly to the pm received or if he wishes directly to the anwser form for the pm received.

if you include the answer link it might be usefull to include the pm message text in the email. Do this by just adding $message in your template.

1 change in private.php
and one template change.

have fun.
tina

Kars10 04-22-2003 12:10 PM

Cool, exactly what i was looking for!! :D

Thanks Tina

[high]* Kars10 klicks install![/high]

Bison 04-22-2003 04:32 PM

Well, this satisfies me!

Now I have them both (Thread notification w/message & PM Noticication w/message)!

Boofo 04-22-2003 06:40 PM

If you add this:

PHP Code:

$the_pm_id $DB_site->insert_id(); 

right below this:

PHP Code:

$DB_site->query("INSERT INTO privatemessage (privatemessageid,userid,touserid,fromuserid,title,message,dateline,showsignature,iconid,messageread,folderid,receipt) VALUES (NULL,$touserinfo[userid],$touserinfo[userid],$bbuserinfo[userid],'".addslashes(htmlspecialchars($title))."','".addslashes($message)."',".time().",'$signature','$iconid',0,0,$receipt)"); 

and put this as a link to the private message, you can save making a new query. ;)

PHP Code:

$bburl/private.php?action=show&privatemessageid=$the_pm_id 


tkeil69575 04-23-2003 10:39 AM

hi boofo,
thanks for the input ;)
I always thought accessing the databank was the same thing - doesnt make much difference if your reading from it or writing to it an extra time. correct me if im wrong.

greets
tina

mwhoob 04-23-2003 01:14 PM

can see screen shot

tkeil69575 04-23-2003 01:28 PM

hi mwhoob,
no screenshot - its just two links in an email. im sure you can imagine how that will look.

greets tina

Boofo 04-23-2003 06:05 PM

Quote:

Today at 05:39 AM tkeil69575 said this in Post #5
hi boofo,
thanks for the input ;)
I always thought accessing the databank was the same thing - doesnt make much difference if your reading from it or writing to it an extra time. correct me if im wrong.

greets
tina

The code I quoted was from a hack that TWTCommish did a while back. Anytime I can save a query, I usually do it that way. Either way will work fine, though. ;)

msimplay 05-12-2003 01:22 PM

i like hacks to be made for 2.3 or updated cuz am on Vb 2.30 release 3

Erwin 05-13-2003 12:05 AM

Use TWTCommish's version which doesn't use a query like Boofo said. We use it here too. :)


All times are GMT. The time now is 12:34 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.01217 seconds
  • Memory Usage 1,736KB
  • 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
  • (1)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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