Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 02-22-2009, 01:08 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Hooks related to private messages not working?

Hi there,

is it possible that there is some feature/function or something else that prevents plugins that hook some private message related stuff from being executed? I checked the general settings for hooks, but there I can just enable or disable hooks completely.
Maybe its just me, but I tried to add a hook for private_insertpm_complete and it just did nothing. First I checked my code again and again, added ebug outputs, and in the end, I just typed in some random stuff that is not valid PHP Code, so I expected to get a "parse error in eval()'d code" when I would try to send a private message, but it still worked, no errors.
Then I tried to hook pmdata_postsave, but also no luck.
And yes, I selected "activate this plugin"
Other hooks work just fine, like reputation_add_complete...

Any help would be appreciated.
Reply With Quote
  #2  
Old 02-22-2009, 01:29 PM
ragtek ragtek is offline
 
Join Date: Mar 2006
Location: austria, croatia
Posts: 1,630
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

whats happening if you try [php]die('here it should stop'); ???
thats the way, i debug/check my plugins/hook positions
Reply With Quote
  #3  
Old 02-22-2009, 06:09 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Just tried that, and it still executes as if there was no plugin
Reply With Quote
  #4  
Old 02-24-2009, 01:03 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Could some other addon or plugin cause this, technically?
There are no plugins that directly hook any private message stuff, but still...

This is really annoying and I have no clue where to start looking for the cause.
Reply With Quote
  #5  
Old 02-24-2009, 02:26 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Are you sure you are doing an action that actually uses the plugin where you have it hooked?
Reply With Quote
  #6  
Old 02-24-2009, 03:43 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Well... private_insertpm_complete should definetely be triggered when you send a pm, no?
At least as far as I understand by reading the source of private.php
Reply With Quote
  #7  
Old 02-24-2009, 04:24 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

That hook should get processed if everything is fine in the PM. Is the PM being sent?
Reply With Quote
  #8  
Old 02-24-2009, 04:49 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yep, I already annoyed several people in my forum with test messages.
I still have die("test"); as plugin code, but it just takes me to my inbox again after sending.
Also tried to hook private_insertpm_process, which should be triggered both, when actually sending the pm and when just displaying a preview... But no luck.

Its either me being very stupid or something is really broken... (Running 3.6.7 btw)

EDIT: Hooking private_start works...
Reply With Quote
  #9  
Old 02-24-2009, 05:02 PM
ragtek ragtek is offline
 
Join Date: Mar 2006
Location: austria, croatia
Posts: 1,630
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Strange, if i create a plugin at insertpm_complete with die('here'); it stops here

have you maybe some other plugins at this hook which redirect on some other side?
Reply With Quote
  #10  
Old 02-24-2009, 05:32 PM
Zahl Zahl is offline
 
Join Date: Jun 2008
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No, there are no private_* related plugins, that's what confuses me too.
I'm gonna disable all addons except mine now, let's see if that helps.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:00 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.11106 seconds
  • Memory Usage 2,246KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.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
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete