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
  #882  
Old 02-02-2008, 10:12 AM
Charles_1 Charles_1 is offline
 
Join Date: Jun 2006
Location: Czech Republic, Brno
Posts: 75
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Deety View Post
I would like to have the form post new threads in multiple forums selected by checkboxes.

This code seems to work well for selecting one $formforumid, but the first two "else" statements would prevent multiple selections, and taking them out did no good.

I'm guessing the issue may be that $formforumid can't be assigned multiple values (i.e., $formforumid = "1,2,3" or some such), but hopefully it can and I'm just missing the language that will do it. Easy answers are nice.

If anyone has a suggestion to get multiple forums working, I'll make the edit to the original form and post it as an example so it's easy for the next person. Thanks for any ideas...

PHP Code:
if ($checkboxchoice1_1 1)
{
$formforumid "1";
}
else
if (
$checkboxchoice1_2 1)
{
$formforumid "2";
}
else
if (
$checkboxchoice1_3 1)
{
$formforumid "3";
}
else
$formforumid "4"
Quote:
Originally Posted by Grimbone View Post
In the code below. how would I go about sending a post to 2 different forums?

Code:
$formforumid = "13";
I am trying to get this to post to both a regular section of the forums and to a private section.
Quote:
Originally Posted by CremeEgg View Post
Anybody know what I would have to change with this section to get it to post to 2 forums?

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 = "x";
I am interested in this too. I tried to find solution, but without luck :-(. Could some coder help please?
Reply With Quote
  #883  
Old 02-03-2008, 01:30 AM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by RedGTiVR6 View Post
Quick question regarding the email form functionality.

I'm going to have a field where the user can enter their email address. This form will be sent to our ticket processing que. I'd like to be able to pull the users email addy from this field and have the email be sent to the email I've entered in the code under the email that's in the field.

Hope that makes sense.

Anyone know if that's possible?
Ok - so I've figured out how to have the form go to an email address that's been entered ON the form, but I can't figure out how to have the email appear to be sent BY the email on the form...

Anyone?
Reply With Quote
  #884  
Old 02-03-2008, 12:25 PM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

If you're using the form to create a new thread and you're allowing for custom thread titles (I do use the form for entering book reviews, thread title will be the book title), you need to be aware that the limit for thread titles is 85 charakters. The hack does not check for this. So if your thread title is > 85 charakters, the thread creation will fail, resulting in a "no thread specified"-error during redirection.
Reply With Quote
  #885  
Old 02-03-2008, 04:28 PM
baz_kingfish's Avatar
baz_kingfish baz_kingfish is offline
 
Join Date: Jan 2008
Posts: 34
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OK, I have been reading this thread most of the morning trying to decide if I have the wherewithall to implement this hack. I am a novice, but I have a pretty good confidence that I can figure it out...given a little help here....but what I am not understanding is how the "multiple" forms are created. Do you have to install the hack everytime you want to create a new form and use a different name or is there a "Add/Create new form" in the AdminCP under this Product/Plugin manager's screen that Adds the new forms and templates that then need to be edited as discussed throughout this thread? I hope it is as I have described so that once I successfully build my first form the others will be easier to figure out. Please advise.
Reply With Quote
  #886  
Old 02-03-2008, 09:25 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by cellarius View Post
If you're using the form to create a new thread and you're allowing for custom thread titles (I do use the form for entering book reviews, thread title will be the book title), you need to be aware that the limit for thread titles is 85 charakters. The hack does not check for this. So if your thread title is > 85 charakters, the thread creation will fail, resulting in a "no thread specified"-error during redirection.
Unless you have changed that in your settings...
Reply With Quote
  #887  
Old 02-03-2008, 09:58 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by baz_kingfish View Post
but what I am not understanding is how the "multiple" forms are created. Do you have to install the hack everytime you want to create a new form and use a different name or is there a "Add/Create new form" in the AdminCP under this Product/Plugin manager's screen that Adds the new forms and templates that then need to be edited as discussed throughout this thread? I hope it is as I have described so that once I successfully build my first form the others will be easier to figure out. Please advise.
There is no manager screen.

If you download and install the mod, the instructions are in the top part of the plug-in.

You don't have to install it multiple times. you just create a new plug-in and new set of templates for each form you want.

It takes a bit to understand what's going on with it and how it works but it's a great way to learn some PHP and a bit about how the forum works.
Reply With Quote
  #888  
Old 02-04-2008, 01:04 AM
attroll's Avatar
attroll attroll is offline
 
Join Date: Jan 2003
Location: Litchfield, Me
Posts: 664
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by baz_kingfish View Post
OK, I have been reading this thread most of the morning trying to decide if I have the wherewithall to implement this hack. I am a novice, but I have a pretty good confidence that I can figure it out...given a little help here....but what I am not understanding is how the "multiple" forms are created. Do you have to install the hack everytime you want to create a new form and use a different name or is there a "Add/Create new form" in the AdminCP under this Product/Plugin manager's screen that Adds the new forms and templates that then need to be edited as discussed throughout this thread? I hope it is as I have described so that once I successfully build my first form the others will be easier to figure out. Please advise.
Yes you have to install the hack for each form you want to use. So if you want to use it for two forms you have to have two installs.
Reply With Quote
  #889  
Old 02-04-2008, 12:26 PM
RedGTiVR6 RedGTiVR6 is offline
 
Join Date: Dec 2006
Location: Little Elm, TX
Posts: 817
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You don't reinstall it. You just create the plug-in again in the AdminCP....
Reply With Quote
  #890  
Old 02-04-2008, 04:08 PM
attroll's Avatar
attroll attroll is offline
 
Join Date: Jan 2003
Location: Litchfield, Me
Posts: 664
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by RedGTiVR6 View Post
You don't reinstall it. You just create the plug-in again in the AdminCP....
You are right. My explantion is wrong. You would have to create another plug-in and two more template files with different name and change that in you newly installed plug-in.
Reply With Quote
  #891  
Old 02-04-2008, 05:01 PM
baz_kingfish's Avatar
baz_kingfish baz_kingfish is offline
 
Join Date: Jan 2008
Posts: 34
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Bummer...

Guess I need to go buy "PHP for Dummies"!

Thank you for the feedback. It would be great if someone took this hack and built an AdminCP user interface. for us rookies to be able to build and hook forms from within the Admin CP. I would be willing to contribute to that effort.

Keep me posted if that becomes a reality.
KF
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 03:59 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.05502 seconds
  • Memory Usage 2,340KB
  • 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
  • (2)bbcode_code
  • (1)bbcode_php
  • (8)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
  • (4)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