Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 3.6 > vBulletin 3.6 Add-ons
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools
Custom Thread Fields Details »»
Custom Thread Fields
Version: 1.3.0, by harmor19 harmor19 is offline
Developer Last Online: May 2023 Show Printable Version Email this Page

Category: New Posting Features - Version: 3.6.4 Rating:
Released: 10-07-2006 Last Update: 05-03-2007 Installs: 221
DB Changes Uses Plugins Template Edits
 
No support by the author.

What you can do with this hack is add multiple fields when someone creates a new thread. You can specify what fields can go in which forums.

To add, edit, or delete a custom field go into your ACP
Forums & Moderators --> Threads Field Manager

################## Updates ##################
1.0.0 - Initial Release
1.1.0 - Fixed bug
1.2.2 - Added the ability to add a field to multiple forums more easily
1.3.0 - Fixed some crucial bugs
1.4.0 - Added more features
################## Updates ##################

If you have installed this add-on on your board please click Install to the bottom right of this post
You are not permitted to redistribute this add-on on any site.
If you feel this add-on deserves Mod of the Month please click to nominate it

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #72  
Old 11-05-2006, 02:05 AM
taydu taydu is offline
 
Join Date: Oct 2006
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

please excuse me but where do I go to edit ???

Quote:
Go to ur plugins
edit: Custom Thread Forms [newthread_post_start]
Reply With Quote
  #73  
Old 11-05-2006, 05:53 AM
ry215 ry215 is offline
 
Join Date: Apr 2006
Location: Paraguay
Posts: 508
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

So I downloaded the zip file from Harmor, followed the instruction...even overwrite the old cpnav_custom...

When I tried to import the xml file, it give me error message...

any help is appreciated.
Reply With Quote
  #74  
Old 11-05-2006, 10:10 AM
harmor19 harmor19 is offline
 
Join Date: Apr 2005
Posts: 1,324
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

What was the error?
Reply With Quote
  #75  
Old 11-05-2006, 05:31 PM
ry215 ry215 is offline
 
Join Date: Apr 2006
Location: Paraguay
Posts: 508
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

here is the error message....

Invalid SQL:
CREATE TABLE `d60299324custom_thread_forms` (
`custom_formid` mediumint(10) unsigned NOT NULL auto_increment,
`forumid` mediumint(10) unsigned NOT NULL default '',
`title` varchar(130) NOT NULL default '',
PRIMARY KEY (`custom_formid`)
);;

MySQL Error : Invalid default value for 'forumid'
Error Number : 1067
Date : Sunday, November 5th 2006 @ 02:28:27 PM
Script : http://www.tinhthoviet.com/forum/adm...=productimport
Referrer : http://www.tinhthoviet.com/forum/adm...?do=productadd
IP Address : 71.225.126.57
Username : nhk
Classname : vb_database
Reply With Quote
  #76  
Old 11-05-2006, 05:55 PM
LaCN LaCN is offline
 
Join Date: Feb 2005
Posts: 76
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by taydu
please excuse me but where do I go to edit ???
in your admin panel / Manage Plugins

You see the plugin Custom Thread Forms [newthread_post_start] in there
Reply With Quote
  #77  
Old 11-06-2006, 05:22 AM
taydu taydu is offline
 
Join Date: Oct 2006
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks LaCN it work like charm
Reply With Quote
  #78  
Old 11-08-2006, 08:37 AM
taydu taydu is offline
 
Join Date: Oct 2006
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Please help my custom thread field doesn't goes to the new line after each custom field

custom field 1: xxx custom field 2: yyy custom field 3: zzz

I want it like this

custom field 1: xxx
custom field 2: yyy
custom field 3: zzz

Message

follow is the code from newthread_post_start

PHP Code:
$getcustomthreadfields $db->query_read("SELECT * FROM " TABLE_PREFIX "custom_thread_forms ");
  while(
$forms $db->fetch_array($getcustomthreadfields))
  {

    
$custom_formid "custom_$forms[custom_formid]";
    
$value htmlspecialchars($_POST[$custom_formid]);
    
    

    if(
$forms['required'] == 1)
    {
      if(empty(
$value))
      {
        eval(
standard_error(fetch_error('fill_in_custom_thread_field')));
      }
    }
    
    if(
$forms['forumid'] != "-1")
        {
           
$forumids explode(","$forms['forumid']);

           if(
in_array($foruminfo['forumid'], $forumids))
           {
               
$custom_message .= "[b][color=Red]".$forms['title']."[/color] [/b] ".$value."
"
;  
           }
       }
       
       if(
$forms['forumid'] == "-1")
        {
            
$custom_message .= "<b>".$forms['title']."</b>: $value<br />";
        }
    }

  
$vbulletin->GPC['message'] = "
$custom_message

.$vbulletin->GPC['message']; 
Reply With Quote
  #79  
Old 11-08-2006, 10:25 AM
jaks jaks is offline
 
Join Date: Dec 2004
Location: Toronto
Posts: 147
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Guess my question was missed?
https://vborg.vbsupport.ru/showpost....7&postcount=69

No I haven't clicked install yet because I haven't installed yet. Just asking questions before hand to know if it will work how I want first.
Reply With Quote
  #80  
Old 11-09-2006, 08:54 PM
taydu taydu is offline
 
Join Date: Oct 2006
Posts: 103
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it would be nice to not display the custom fields thread in the post if nothing is available. This way when user edit there post it won't be doublicate

field 1
field 2

if edit one

field 1
field 2
field 1
field 2
Reply With Quote
  #81  
Old 11-13-2006, 02:26 PM
FractalizeR's Avatar
FractalizeR FractalizeR is offline
 
Join Date: Oct 2005
Location: Russia, Moscow
Posts: 368
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
`forumid` mediumint(10) unsigned NOT NULL default '',
Your MySQL is running in STRICT mode. Change this line to

Quote:
`forumid` mediumint(10) unsigned NOT NULL default 0,
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 05:03 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.05267 seconds
  • Memory Usage 2,322KB
  • Queries Executed 25 (?)
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)bbcode_php
  • (4)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)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