vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=15)
-   -   Thread custom field (https://vborg.vbsupport.ru/showthread.php?t=224335)

ehabzaky 10-01-2009 09:37 AM

Thread custom field
 
Hello,

I have added a new custom field to my thread table.

Now I want to access this field in the threadbit template

I used this code

$thread[filedname]

but it doesn't work :mad: I tried the same code with original thread fields like

$thread[threadid]

I found it working.

I also used the same syntax $thread[filedname] in the postbit Template and it is working OK :confused:

Only in threadbit it is not working!

Could anybody help me please.

Regards,
Ehab Zaky

Lynne 10-01-2009 02:44 PM

Did you check the query that is used just prior to the threadbit being evaled and make sure your variable is selected there? If they just selected thread.threadid and thread.title, then your thread.fieldname is not going to be available for use unless you add it to the query.

Arkham 10-01-2009 06:53 PM

Quote:

Originally Posted by Lynne (Post 1893306)
Did you check the query that is used just prior to the threadbit being evaled and make sure your variable is selected there? If they just selected thread.threadid and thread.title, then your thread.fieldname is not going to be available for use unless you add it to the query.

Ah, this might be something I can use to accomplish this.

Where would he/we/I put the thread.<customfieldname>?


All times are GMT. The time now is 08:57 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.00978 seconds
  • Memory Usage 1,712KB
  • 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)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (3)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