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
Form Hack Details »»
Form Hack
Version: 4.1, by Abe1 Abe1 is offline
Developer Last Online: Jun 2010 Show Printable Version Email this Page

Category: New Posting Features - Version: 3.6.x Rating:
Released: 09-14-2006 Last Update: 04-23-2008 Installs: 1216
Uses Plugins Template Edits
 
No support by the author.

Form Hack 4.1


Features:

Ever wanted an online form that a user can fill out, which when submitted gets:
  • Posted into a new thread in a forum of your choice
  • Create a new poll in the new thread with options of your choice
  • Posted as a reply in an existing thread of your choice
  • PMed to you or someone else
  • Emailed to an email address you specify
  • Choose to redirect to the post, thread or forum, or a custom thank you message
  • Choose to redirect to edit post
  • See a preview before they submit

Or any combination or all of the above?

Well, this is the hack for you!

You can use this for:
  • Moderator Applications
  • Quiz Submit Form which gets PMed to a moderator
  • Contact Form that goes to PM, email or thread
  • Guests to apply to be members
  • Report a Moderator form that goes as a PM to you
  • Guests can PM you for whatever reason
  • Order form to buy things
  • Donation form
  • News or Articles submissions that can go straight to a thread

Or anything you like - this hack is totally customizable via the AdminCP.

The beauty of this hack is that once you install this hack, to make a new form all you need to do is copy the main hook, rename it to whatever you want, edit the variables in the hook, and you have a totally new form!!! You do not need to touch the templates again, but can always create new ones and use different templates for different forms.

Format of the form:
  • One main input question
  • 3 Radio buttons Choice questions
  • 3 Normal text input questions
  • 1 Drop down menu
  • 3 Check boxes
  • 1 Long answer question
  • 1 VB message editor text box question
  • Upload attachments

This is customizable via the hook.

Also:
  • You can set the usergroups you want access to this form.
  • Depending on your forum permissions, if the new thread is in a public forum, members can reply to it. This hack allows a form to submit the new thread or post wherever you want it to go.
  • Force the user to answer all questions.

INSTALLATION
Easy - takes only a few minutes:
  • Import the XML into products. (admin cp -> Plug-in System -> Manage Products -> Add/Import Product)
  • Edit the main plug-in - the instructions are all inside the hook itself, in the top half. Follow the instructions carefully!
  • To get to the form, go to: /newthread.php?do=form (change "form" to the name of your form if you have few)

Done!

Use this hack to make as many forms as you like!

Enjoy!

Updates:

Version 4.0: (09/15/2006)
  • Ported over for vb3.6
  • Send to multiple emails.
  • Send multiple PMs.
  • Parse emails for BBCode
  • And finally, ATTACHMENTS!

Version 4.1: (04/24/2008)
  • Fixed for vb 3.6.10
  • Small bug fixed.
  • List of the 2 quick edits are in the zip file so you don't have to start making a form from scratch.

MAKE SURE YOU CLICK INSTALL!
You will get an email when a new version is released.

Abe1 with rights from Dr Erwin Loh

Supporters / CoAuthors

Show Your Support

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

Comments
  #72  
Old 09-18-2006, 11:40 PM
R.Caldwell R.Caldwell is offline
 
Join Date: Aug 2006
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ctrl-alt-del
I imagine it's not as simple as:

$formforumid = "$dropdownanswer1";

I need a way of associating the selection to a forumID. Thanks again!
I've tried various ways of getting this to work, and all I get is some wierd errors...

I have PM'd Abe1, but have yet to hear anything back.
If you would like to Collab on it, let me know.
Reply With Quote
  #73  
Old 09-19-2006, 02:59 AM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ctrl-alt-del
A WYSIWYG editor would put this hack over the top!

I have yet another question I'm hoping be answered with relative ease. Is it possible to add a drop down menu to a form that posts either a new thread or reply to a thread in a specific form based on the selection of the drop down?

Example: Selections could be The Lounge, vBulletin Discussions, Service Requests, etc. Submitting the form would create the thread in the drop down selection. Thanks!!
There is a WYSIWYG editor already.
Reply With Quote
  #74  
Old 09-19-2006, 02:59 AM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by R.Caldwell
I've tried various ways of getting this to work, and all I get is some wierd errors...

I have PM'd Abe1, but have yet to hear anything back.
If you would like to Collab on it, let me know.
I dont have time to write up all the info. Basicly make sure you are using the right varible. It has to be imported the same way as all other answers are imported.
Reply With Quote
  #75  
Old 09-19-2006, 03:00 AM
ctrl-alt-del ctrl-alt-del is offline
 
Join Date: Jul 2006
Posts: 54
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes, I meant for the forms.
Reply With Quote
  #76  
Old 09-19-2006, 03:02 AM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ctrl-alt-del
Yes, I meant for the forms.
There is a WYSIWYG editor in the form. What are you talking about????
Reply With Quote
  #77  
Old 09-19-2006, 03:07 AM
ctrl-alt-del ctrl-alt-del is offline
 
Join Date: Jul 2006
Posts: 54
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Apologies, we're missing each other....I know there's a WYSIWYG editor when you're entering/submitting information within a form. But it would be great to have one when creating the forms. (form and formanswers in addition to the separate plugin/hook that needs to be created)

I know it's probably a huge task to undergo something like this.

Can you help us figure out the drop down box question?
Reply With Quote
  #78  
Old 09-19-2006, 01:33 PM
R.Caldwell R.Caldwell is offline
 
Join Date: Aug 2006
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

so I need to have the forumID in the answer templates?

I didn't put it in there because I thought it wouldnt matter, I will try what I was doing last time and see if I can get it to work.
Reply With Quote
  #79  
Old 09-20-2006, 03:53 AM
UManiac's Avatar
UManiac UManiac is offline
 
Join Date: May 2002
Location: DC
Posts: 72
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does this ONLY work on 3.6?
Reply With Quote
  #80  
Old 09-20-2006, 10:05 AM
Abe1's Avatar
Abe1 Abe1 is offline
 
Join Date: Feb 2004
Location: I LOVE New York!
Posts: 2,886
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by UManiac
Does this ONLY work on 3.6?
I think if you try to import this into vb3.5 you may get an error.

Also, I'm not sure the attachments work the same in vb 3.5
Reply With Quote
  #81  
Old 09-20-2006, 01:33 PM
R.Caldwell R.Caldwell is offline
 
Join Date: Aug 2006
Posts: 18
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Ok, I have tried just about everything I can think of, I get these errors when submitting -

Code:
Warning: Cannot use a scalar value as an array in /includes/functions_newpost.php on line 348

Fatal error: Unable to proceed with save while $errors array is not empty in class vb_datamanager_pm in /includes/class_dm.php on line 763
This happens when I have send PM enabled. With my addon's for the drop down forum menu.

Here is a snip of my code I have on my form now.

PHP Code:
// Part 1 
$vbulletin->input->clean_array_gpc('p', array( 
'dropforum1' => TYPE_STR
'dropforum2' => TYPE_STR
There is more code after this, this is only the relevent selections.

PHP Code:
// Part 2 
$dropforum1 $vbulletin->GPC['dropforum1']; 
$dropforum2 $vbulletin->GPC['dropforum2']; 
There is more code after this, this is only the relevent selections.

PHP Code:
//FORUM TO POST NEW THREAD IN 
//You CAN make this number a variable. You can have a drop down menu or in the link like do=form&f=1. Make sure you add it the variables list. 
$formforumid "$dropdownforum1"

$dropforum1 "2"
$dropforum2 "4"
Form Template additions
PHP Code:
<tr>
<
td class="alt1" valign="middle">
<
b>$dropdownforum1</b>:
<
td class="alt1" valign="middle" colspan="2">
<
select name="dropdownforum1">
<
option value="$dropdownforum1<if condition="$dropdownforum1 == $dropforum1">selected="selected"</if>>$dropforum1</option>
<
option value="$dropdownforum1<if condition="$dropdownforum1 == $dropforum2">selected="selected"</if>>$dropforum2</option>
</
select></td>
</
td>
</
tr
Form Answers template
PHP Code:
$dropdownforum1
$dropforum1
$dropforum2 
I dont know why it isn't working, I'm sure its something small I have missed, I am using Drop Down choices throughout the form, so I know my coding is correct for that on my form. I'm just not sure where I missed something or what, but maybe this can help someone else out.

I'm also willing to pay for service to help me get this form working with the Drop Down Choice for which form to post to.
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 09:28 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.08124 seconds
  • Memory Usage 2,339KB
  • Queries Executed 26 (?)
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_code
  • (5)bbcode_php
  • (5)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
  • (3)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