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
  #1032  
Old 05-17-2008, 10:56 PM
uberjon uberjon is offline
 
Join Date: Sep 2006
Posts: 22
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

read this works on 3.7 and appears to with stock .xml file. however when i attempt to use my customized one. i get a white page? cant diagnose the error with a white page with no output source code.

anyone have any ideas?

edit:

*blush* i figured it out! template naming mismatch
Reply With Quote
  #1033  
Old 05-18-2008, 04:52 AM
ccplim ccplim is offline
 
Join Date: Feb 2005
Location: SG
Posts: 89
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I am trying to set up some conditional check for my fields but where should I put them in? In the plugin itself or the main template? I have been playing around with the codes for days but just can't seem to get the conditional syntex right :down:

What is going to happen is that I will have 3 fields in my form, namely $radiochoice1a, $radiochoice1b, and normalanswer1.

If a member select $radiochoice1a as his answer, normalanswer1 will be disabled and no information can be entered in that field.

Else, if the member select $radiochoice1b as his answer, normalanswer1 will be enable.

Thanks!
Reply With Quote
  #1034  
Old 05-18-2008, 08:09 AM
ccplim ccplim is offline
 
Join Date: Feb 2005
Location: SG
Posts: 89
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How can I remove the VB text input area? I tried to remove '$messagearea' but the three buttons (Submit, Preview, Reset) below also disappeared
Reply With Quote
  #1035  
Old 05-18-2008, 06:11 PM
Deepdog009's Avatar
Deepdog009 Deepdog009 is offline
 
Join Date: Dec 2004
Location: Almost out of PHP TZone
Posts: 485
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ccplim View Post
I am trying to set up some conditional check for my fields but where should I put them in? In the plugin itself or the main template? I have been playing around with the codes for days but just can't seem to get the conditional syntex right :down:

What is going to happen is that I will have 3 fields in my form, namely $radiochoice1a, $radiochoice1b, and normalanswer1.

If a member select $radiochoice1a as his answer, normalanswer1 will be disabled and no information can be entered in that field.

Else, if the member select $radiochoice1b as his answer, normalanswer1 will be enable.

Thanks!
ccplim,,,
I haven't had much time to help recently because of my job,,, but yeah you can use the standard if conditional to work out your issue...

What I recommend is downloading a few easy mods and take a look at the XML code... Look for mods that use the if statment allot...

Im still half way out of the PHP twilight zone and on top of that my job wont allow my ball and chain to come off very often...

Take a look at this site...>>> PHP HELPER

If you still need help after checking over there,,, Give me until tuesday and I will assist U...


*************************************************


ccplim,,,
VB Text edit...>>> delete both lines listed below...

HTML Code:
<td class="alt2" valign="middle" colspan="3">
<b>$vbtextquestion</b><br />    <<<......{{{delete this}}}
$vbtextexplain       <<<......{{{delete this}}}
<div align="center">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td>
$messagearea
</td>
</tr>
</table>
</div>
</td>
</tr>
<if condition="$attachmentoption">
<tr>
<td class="alt1" colspan="3" align="center">
<div style="width:$stylevar[formwidth]" align="$stylevar[left]">$attachmentoption</div>
</td>
</tr>
</if>
<tr>
<td valign="top" colspan="3">
<p align="center">
<input type="submit" value="Submit" name="submit" style="font-family: Verdana; font-size: 10pt" class="button" />
<input type="submit" value="Preview" name="submit" style="font-family: Verdana; font-size: 10pt" class="button" />
<input type="reset" value="Reset" name="reset" style="font-family: Verdana; font-size: 10pt" class="button" />
</p></td></tr>
</table>

</form>

That should do the trick...



*************************************************


ccplim,,,
Using the disable feature seems to work better with ajax,,, the only problem is that I haven't worked with ajax modifications yet... Too many things going on now,,, so maybe next month If Im not burnt out with mod updates,,, I will attempt adding some ajax...


*************************************************


uberjon,,, Beauts!
Reply With Quote
  #1036  
Old 05-19-2008, 02:48 AM
ccplim ccplim is offline
 
Join Date: Feb 2005
Location: SG
Posts: 89
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Deepdog009 View Post
ccplim,,,
I haven't had much time to help recently because of my job,,, but yeah you can use the standard if conditional to work out your issue...

What I recommend is downloading a few easy mods and take a look at the XML code... Look for mods that use the if statment allot...

Im still half way out of the PHP twilight zone and on top of that my job wont allow my ball and chain to come off very often...

Take a look at this site...>>> PHP HELPER

If you still need help after checking over there,,, Give me until tuesday and I will assist U...
Thanks for the link pal I'll take a look at it and see how things can progress from there :up:
Reply With Quote
  #1037  
Old 05-20-2008, 02:24 AM
rwoscott rwoscott is offline
 
Join Date: Jan 2007
Location: Melbourne
Posts: 142
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've managed to customise my form, (finally) and can PM it to myself, but I can't seem to get the submit to a forum work. I've set the Forum id to a couple of forums to ensure it works, but alas it does not.

Anyone have an idea as to why it may not work?
Will supply the link if needed.
Reply With Quote
  #1038  
Old 05-20-2008, 01:07 PM
grimmer grimmer is offline
 
Join Date: Oct 2005
Posts: 11
Благодарил(а): 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"
Bump for a question that about a dozen people here including myself have.
Reply With Quote
  #1039  
Old 05-20-2008, 11:31 PM
Smiry Kin's's Avatar
Smiry Kin's Smiry Kin's is offline
 
Join Date: Dec 2005
Location: United Kingdom!
Posts: 954
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

does this work in 3.7.?

as looking for something like this again
Reply With Quote
  #1040  
Old 05-22-2008, 02:15 PM
ccplim ccplim is offline
 
Join Date: Feb 2005
Location: SG
Posts: 89
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Oh my goodness..... my form shown up alright in Internet Explorer (see attached "Internet explorer.jpg) but not in Firefox (see attached "Firefox.jpg).

What could have gone wrong?
Reply With Quote
  #1041  
Old 05-22-2008, 07:50 PM
Alteran Ancient's Avatar
Alteran Ancient Alteran Ancient is offline
 
Join Date: May 2005
Location: Atlantis
Posts: 40
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ccplim View Post
Oh my goodness..... my form shown up alright in Internet Explorer (see attached "Internet explorer.jpg) but not in Firefox (see attached "Firefox.jpg).

What could have gone wrong?
It's a good thing I refuse to use Firefox. It's an over-rated, worshipless piece of pap that I only ever touch for the plugins people make for it, such as Download managers. I come for their work, not the work of Mozilla.

At least IE8 will come out with Standard mode available.
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 06:05 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.07199 seconds
  • Memory Usage 2,342KB
  • 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_html
  • (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
  • (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