Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 08-10-2011, 08:27 PM
XLCR GODFATHER XLCR GODFATHER is offline
 
Join Date: Mar 2010
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Can't find correct hook

Please help I am writing a plugin to add some information to member profiles to show in the attached location but I can't find the correct hook. This area is shows for custom profile field categories and it appears that if you edit the memberinfo_block_profilefield template information will show but on every custom profile field category tab you click on. I cant find an existing variable to segregate the data so it only shows in 1 or the other category and I really am not sure how to establish my on variable for if a tab is clicked so I am probably going to merge the 2 categories into 1. I am running in debug mode on my test site but it gives a pretty big list. I have tried the ones that seem logical but no luck. Can anyone help me?
I have gotten other plugins to show where I want them by registering, rendering and caching templates but this one is driving me nuts...
Attached Images
File Type: jpg help.jpg (44.1 KB, 0 views)
Reply With Quote
  #2  
Old 08-11-2011, 01:36 AM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

On your test site where you are writing this, go into debug mode (there is an article on how to do this) and then the list of all available hooks for that page will be listed on the bottom right. See if those work. You can usually narrow it down by knowing when the code needs to be processed.
Reply With Quote
  #3  
Old 08-11-2011, 04:58 AM
XLCR GODFATHER XLCR GODFATHER is offline
 
Join Date: Mar 2010
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you lynne. I have tried that but it still is not working, I cant figure this one out and is driving me nuts. That was why I hoped with the attached image someone might point me at the correct hook so I can make sure it is not something else wrong.
Reply With Quote
  #4  
Old 08-11-2011, 05:06 AM
Badshah93 Badshah93 is offline
 
Join Date: Jun 2010
Location: India
Posts: 505
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

right hook for this is "member_complete"

But whats your php code ?
Reply With Quote
  #5  
Old 08-11-2011, 05:50 AM
XLCR GODFATHER XLCR GODFATHER is offline
 
Join Date: Mar 2010
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Updated to include the hook you provided
Code:
$templater = vB_Template::create('codinfo');
$template_hook[member_complete] .= $templater->render();
Yes, I also Cached the template
Template only contains simple html to display some images

Am I missing anything?

--------------- Added [DATE]1313045447[/DATE] at [TIME]1313045447[/TIME] ---------------

BTW Thank You Sherif.

--------------- Added [DATE]1313048130[/DATE] at [TIME]1313048130[/TIME] ---------------

I can see via debug mode that the template is being called but it is not rendering anywhere on the profile let alone where I want it to render. I have even tried adding {vb:raw codinfo} to the template I want it attached to.
Reply With Quote
  #6  
Old 08-11-2011, 07:28 AM
Badshah93 Badshah93 is offline
 
Join Date: Jun 2010
Location: India
Posts: 505
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by XLCR GODFATHER View Post
Updated to include the hook you provided
Code:
$templater = vB_Template::create('codinfo');
$template_hook[member_complete] .= $templater->render();
Yes, I also Cached the template
Template only contains simple html to display some images

Am I missing anything?

--------------- Added [DATE]1313045447[/DATE] at [TIME]1313045447[/TIME] ---------------

BTW Thank You Sherif.

--------------- Added [DATE]1313048130[/DATE] at [TIME]1313048130[/TIME] ---------------

I can see via debug mode that the template is being called but it is not rendering anywhere on the profile let alone where I want it to render. I have even tried adding {vb:raw codinfo} to the template I want it attached to.


member_complete is a plugin hook not template hook..

I would suggest you to refer this article

Code:
https://vborg.vbsupport.ru/showthread.php?t=265971
Reply With Quote
Благодарность от:
XLCR GODFATHER
  #7  
Old 08-11-2011, 01:38 PM
XLCR GODFATHER XLCR GODFATHER is offline
 
Join Date: Mar 2010
Posts: 53
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Perfect! Thank you. now it makes more sense. This will open up for me to do what I wanted.
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 06:13 AM.


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.05525 seconds
  • Memory Usage 2,248KB
  • Queries Executed 14 (?)
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
  • (3)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (7)post_thanks_box
  • (1)post_thanks_box_bit
  • (7)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit
  • (7)post_thanks_postbit_info
  • (7)postbit
  • (1)postbit_attachment
  • (7)postbit_onlinestatus
  • (7)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_postinfo_query
  • fetch_postinfo
  • 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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete