vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   How to edit the files concerned by new thread method (https://vborg.vbsupport.ru/showthread.php?t=275597)

Infoman4ever 12-17-2011 12:22 PM

How to edit the files concerned by new thread method
 
Hey folks :)
I just started VB4 products programming and got the first levels, I need now to modify the thread method a bit, how? I need a new information relative to a new thread -using a particular function- to be added once it's submitted, for this purpose, I modified the table "thread" and added a new column that's done, but what I'm missing is where (templates, plugins, files, ...) and what (just few hints) should I modify to add the new information about the thread?
Really need a push, I have to perform this modification as soon as possible :confused:.
Regards.

kh99 12-17-2011 12:34 PM

I think you'd want to edit the newthread template to add an input field for your data. Then I think the best thing to do would be to look at newthread.php and see how it handles the existing fields. When you're looking in there you'll see where the hooks are. I think it's possible to do what you want using plugins at those hook locations.

Infoman4ever 12-17-2011 12:45 PM

I found a way to do so, I added a new plugin which is linked to the hook "showthread_getinfo", the plugins contains the update query of the new column.
Thank you kh99 very much for giving me some ideas.

kh99 12-17-2011 06:33 PM

I'm glad you got it working - I was trying to figure out how to explain it in more detail, but really the best thing it to just look at the code and see what's happening.


All times are GMT. The time now is 08:23 PM.

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.01690 seconds
  • Memory Usage 1,707KB
  • 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
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)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