vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.8 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=235)
-   -   New Posting Features - Easy Forms - Create a form or multiple forms without php or html knowledge (https://vborg.vbsupport.ru/showthread.php?t=201097)

Simon Lloyd 06-06-2011 08:02 PM

The Author would have to custom that for you as there isn't that option to send it to whichever thread the user of the form chooses, unless you can use stuff like you can in the title like this:
Check the checkbox for which thread to post to and then put {q_1} so question one on your form would be a textbox for a thread id, this is only a guess, give it a go, if not you'll have to wait for the author to answer :)

Nook_Neformat 06-06-2011 09:22 PM

i tried, it doesn't work(

Robert Waanders 07-01-2011 12:43 PM

This is a really great mod! Thank you for this!

hossenpheffer 07-23-2011 02:39 PM

I'm trying to change the New Thread icon/button code to go directly to a specific form. I found a prior post here: Post 459 telling what to do, but I'm not sure "where" to do it.

Can anyone expound on exactly what form and how, where it needs to be altered? I understand the code, just not where to put it.

Much thanks for any help.

Simon Lloyd 07-23-2011 11:51 PM

Take a lookat Bananalive's post below it https://vborg.vbsupport.ru/showpost....&postcount=461 with this go to Admincp>Plugins & Products>Add new plugin
Product: leave this alone
Hook location: newthread_start
Title: Form Button
Excecution Order: leave this alone
Plugin code: add the below changing the forum id's to that of the ones you want to control.
HTML Code:

if (in_array($forumid, array(1,2,3))) {
header( 'Location: http://www.your-site.com/forum/misc.php?do=form&fid=1' ) ;
}


twista46 07-25-2011 06:41 PM

How can i insert my Forum Prefix`s in this Mod and a field for Images ??

hossenpheffer 07-25-2011 11:00 PM

Thanks much to Simon Lloyd. That clarification was just what I needed!

TROLL 07-27-2011 07:26 PM

I have what is probably a very simple question for anyone with PHP experience... (which I unfortunately do not).

In the Form Hook: Form Start: field, I currently have the following code which requires users to have a post count of at least 30 to use the form:

Code:

if($vbulletin->userinfo['posts'] < 30)
{
$errormessage = "You need 30 posts to use this form.";
eval('print_output("' . fetch_template('STANDARD_ERROR') . '");');
}

I would like to add a second requirement here, which also requires users to have joined at least 30 days ago in order to use the form.
I found the following code, but am not sure how to properly add it to what I have currently:

Code:

$vbulletin->userinfo['joindate'] < TIMENOW - (86400 * 30)
Again, I am looking to require that users have at least 30 posts AND have joined at least 30 days ago in order to use the form.

Thanks in advance for the help!

HMBeaty 07-27-2011 07:32 PM

Try this
PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
$errormessage "You need 30 posts to use this form.";
eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');



TROLL 07-27-2011 07:48 PM

Thank you sir! That appears to work with some basic testing. Very much appreciated.

For the record, this is the final code I used, changing the error message to be more approprate:

PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
$errormessage "You do not have permission to create a thread in the Personal Marketplace because you need a post count of at least 30 and to have been a member for at least 30 days to create a thread here.";
eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');



HMBeaty 07-27-2011 07:53 PM

Quote:

Originally Posted by TROLL (Post 2225743)
Thank you sir! That appears to work with some basic testing. Very much appreciated.

For the record, this is the final code I used, changing the error message to be more approprate:

PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
$errormessage "You do not have permission to create a thread in the Personal Marketplace because you need a post count of at least 30 and to have been a member for at least 30 days to create a thread here.";
eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');



To shorten that up, I believe you could also use something like this:
PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
    
standard_error(fetch_error('YOUR_ERROR_PHRASE'));


And go to Add New Phrase > Error Phrase > input your varname, text, etc. and change YOUR_ERROR_PHRASE to the varname you defined

b6gm6n 07-27-2011 11:18 PM

Hi, how can i chose the ID of the thread maker for a submitted form? it seems it's always choosing the admin and posting a thread, just so happens I'm the admin who posted a test and it looked ok, but i wanted my forum bot to make the post, i inserted the bot ID and yet although it takes that information it just appends a a comma and my admin ID in the edit section, how can i get past this?

twista46 08-03-2011 05:04 PM

Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 * 30))
{
$errormessage = "You do not have permission to create a thread in the Personal Marketplace because you need a post count of at least 30 and to have been a member for at least 30 days to create a thread here.";
eval('print_output("' . fetch_template('STANDARD_ERROR') . '");');
}

Nice Tool

but it works not in 3.7 :(:(

twista46 08-06-2011 09:26 PM

No Idea??

hossenpheffer 08-08-2011 11:30 AM

I'm using the first three fields of a form to use as the new thread title. It's critical that the new title display all capital letters. Can some one explain the best way to force uppercase/caps for a given set of questions or field?

Using the 'description' to request the user input only caps is often ignored.

hossenpheffer 08-11-2011 06:35 PM

I've been using the mod New Thread Notification for quite a while, but the instant email alerts have stopped sending with the installation and activation of Easy Forms in the forums that use a form to start a new thread.

I've tried adjusting the execution order around with both of them to no avail. Has anyone else seen this? Thanks in advance for any ideas or solutions.

Simon Lloyd 08-12-2011 02:25 PM

maybe one of them is rewriting the hook thats used

hossenpheffer 08-12-2011 03:01 PM

I expect you're right, or by-passing one? Reviewing the plugin hooks, they don't appear to have any shared hook locations.

Moon Moose 09-05-2011 11:34 AM

I've installed this mod but can't find anywhere to create the form?? Or any clues from endless amounts of posts I have looked through. I just want to put a small "Send your name and address for tickets" form on a an events page in the cms. ??

blind-eddie 09-06-2011 02:23 AM

Quote:

Originally Posted by Moon Moose (Post 2242154)
I've installed this mod but can't find anywhere to create the form?? Or any clues from endless amounts of posts I have looked through. I just want to put a small "Send your name and address for tickets" form on a an events page in the cms. ??

In your quick links drop down, click Forms. It should be at the bottom.
Once you get to the form page the link to create new forms is dead center of page.


http://yoursitecom/forum/misc.php?do=forms

TROLL 09-19-2011 09:35 PM

Quote:

Originally Posted by HMBeaty (Post 2225745)
To shorten that up, I believe you could also use something like this:
PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
    
standard_error(fetch_error('YOUR_ERROR_PHRASE'));


And go to Add New Phrase > Error Phrase > input your varname, text, etc. and change YOUR_ERROR_PHRASE to the varname you defined

Hello,
I found I am having an issue with some users being able to post even though they do not have both requirements: at least 30 posts and have been a member for 30 days. After reviewing the code, it appears that it is currently presented as:
"If you have less than 30 posts AND have been a member for less than 30 days, you receive an error message."
What I would like it to be is:
"If you have less than 30 posts OR have been a member for less than 30 days, you receive an error message."

This will require that users meet both a minimum post requirement and join date requirement, not that they only have to meet one or the other. To accomplish this, can I simply change the "AND" to "OR" in my current code, copied below?

PHP Code:

if($vbulletin->userinfo['posts'] < 30 AND $vbulletin->userinfo['joindate'] < TIMENOW - (86400 30))
{
$errormessage "You do not have permission to create a thread in the Personal Marketplace because you need a post count of at least 30 and to have been a member for at least 30 days to create a thread here.";
eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');



rnmcd 09-21-2011 07:22 PM

What happened to the developers web site that had sample forms on it?:(

Uberguilds 10-17-2011 10:19 PM

Did anyone fix the re-direct issue with vbseo on editing a form's options and saving?

The url is going to index.php#misc after I click "Save Changes."

Example:
The checkboxes, such as "Save to database" don't have a check mark when I marked it so before clicking "Save Changes" and being redirected to #misc.

Uberguilds 10-18-2011 11:46 PM

resolved manually.

"Save to Database" mysql> update vb3_forms set action=5;

Code:


 Field              | Type        | Null | Key | Default                                                                    | Extra          |
+--------------------+--------------+------+-----+-----------------------------------------------------------------------------+----------------+
| fid                | int(11)      | NO  | PRI | NULL                                                                        | auto_increment |
| title              | varchar(255) | NO  |    |                                                                            |                |
| description        | text        | NO  |    | NULL                                                                        |                |
| displayorder      | int(10)      | NO  |    | NULL                                                                        |                |
| action            | varchar(255) | NO  |    | NULL                                                                        |                |
| threadtitle        | varchar(255) | NO  |    |                                                                            |                |
| category          | varchar(255) | NO  |    |                                                                            |                |
| polloptions        | longtext    | NO  |    | NULL                                                                        |                |
| poll              | int(1)      | NO  |    | NULL                                                                        |                |
| publicpoll        | int(1)      | NO  |    | NULL                                                                        |                |
| multiplepoll      | int(1)      | NO  |    | NULL                                                                        |                |
| pollquestion      | varchar(255) | NO  |    | NULL                                                                        |                |
| usergroups        | text        | NO  |    | NULL                                                                        |                |
| submitmessage      | text        | NO  |    | NULL                                                                        |                |
| formoutput        | longtext    | NO  |    | NULL                                                                        |                |
| attach            | int(1)      | NO  |    | 0                                                                          |                |
| preq              | varchar(255) | NO  |    |                                                                          |                |
| pstq              | varchar(255) | NO  |    |
                                                                      |                |
| prea              | varchar(255) | NO  |    |                                                                |                |
| psta              | varchar(255) | NO  |    |
                                                            |                |
| pres              | varchar(255) | NO  |    |                                                                |                |
| psts              | varchar(255) | NO  |    |
                                                              |                |
| pref              | varchar(255) | NO  |    |                                                                            |                |
| pstf              | varchar(255) | NO  |    |                                                                            |                |
| beforesubmit      | longtext    | NO  |    | NULL                                                                        |                |
| formstart          | longtext    | NO  |    | NULL                                                                        |                |
| top                | varchar(255) | NO  |    |{formtitle}

 |                |
| showonfl          | int(1)      | NO  |    | 1                                                                          |                |
| redirect          | int(1)      | NO  |    | 0                                                                          |                |
| redirecturl        | varchar(255) | NO  |    | NULL                                                                        |                |
| pmrec              | varchar(255) | NO  |    | NULL                                                                        |                |
| threadid          | varchar(255) | NO  |    | NULL                                                                        |                |
| forumid            | varchar(255) | NO  |    | NULL                                                                        |                |
| email              | varchar(255) | NO  |    | NULL                                                                        |                |
| polltimeout        | int(3)      | NO  |    | 0                                                                          |                |
| prefixid          | varchar(255) | NO  |    |                                                                            |                |
| preview            | int(1)      | NO  |    | 1                                                                          |                |
| userids            | text        | NO  |    | NULL                                                                        |                |
| submitlimitperuser | varchar(255) | NO  |    |                                                                            |                |


|Jordan| 01-09-2012 05:01 AM

I know thread prefix support is already available, but i dont want the form to be locked to one prefix, i want users to be able to choose the prefix. How could i do this?

CoffeeLovesYou 01-22-2012 12:30 AM

How do you allow users to edit their submission without letting them see and edit everyone's submission?

1F42 02-02-2012 12:59 PM

Read up to page 50 so far ..still reading but not found any one with the same query/mod.

I would like it to post as a new thread in my mgc chatbox notification window as it use to do when I used the standard thread in that forum now im using the form there by default it does not show.

I'm guessing I need to change the code in Newthread_form_complete in the mgc chatbox product to look for forms created as well?

I think it just looks for this at the moment
$vbulletin->db->query_write

Can some one help or at least tell me if i'm on the right track.

Great mod by the way, and amazing support I have seen reading this far, off to read some more because I'll learn more :)

Update read every page and although I see the same old questions being raised, mine never has been it a new question! shame it took me to long to find this mod and it's not supported any more! Ill try posting in the new version.

1F42 02-02-2012 01:21 PM

Quote:

Originally Posted by |Jordan| (Post 2285452)
I know thread prefix support is already available, but i dont want the form to be locked to one prefix, i want users to be able to choose the prefix. How could i do this?

see here
https://vborg.vbsupport.ru/showpost....&postcount=963

tansu 02-09-2012 09:36 AM

Hello,
How can I prevent my users to submit the form more than once?

tansu 02-16-2012 05:43 AM

Quote:

Originally Posted by tansu (Post 2297846)
Hello,
How can I prevent my users to submit the form more than once?

Any ideas?

CoffeeLovesYou 03-03-2012 08:24 PM

Is there a way to add a search function to the Form Results Table?

hpidriver 03-09-2012 08:36 PM

Quote:

Originally Posted by CoffeeLovesYou (Post 2305844)
Is there a way to add a search function to the Form Results Table?

I believe in the latest version of this there is a search button when you view the Form Results Table

Quote:

Originally Posted by bananalive (Post 1803542)
You could use custom question for this:

PHP Code:

require_once(DIR '/includes/functions_prefix.php');
$prefix_options fetch_prefix_html($form['forumid'], $q["$formbit[id]"], true);
$answer '<select name="q_' $formbit[id] . '" id="q_' $formbit[id] . '" class="bginput">';
$answer .= '<option value="">'.$vbphrase[no_prefix_meta].'</option>';
$answer .= $prefix_options;
$answer .= '</select>'


I am using this custom question code, and it shows me the correct choices of prefixes when filling out a form.
However, when I click submit, Easy Forms does not recognize that any prefix was chosen. ie. if the custom coded prefix question is made "compulsory" it always throws the error of : "The form did not submit as the following questions are unanswered: "

Anyone have the prefix option for posting to a new thread working? on vb3.8.6

nascartr 03-25-2012 11:43 PM

Quote:

Originally Posted by bananalive (Post 1767768)
This requires Easy Forms v3.3

Add this into postbit template somewhere (or postbit_legacy)
HTML Code:

<a href="misc.php?do=form&fid=2&username=$post[username]">Trade with $post[username]</a>
Import attached file.

form Hook: Form start

PHP Code:

$hiddenfield1 $vbulletin->input->clean_gpc('g''username'TYPE_NOHTML);
if (empty(
$hiddenfield1))
    {
        
$errormessage "Error, this form needs a username.";
           eval(
'print_output("' fetch_template('STANDARD_ERROR') . '");');
    } 

form Hook: Before Submit

PHP Code:

$hiddenfield1 $vbulletin->input->clean_gpc('p''hiddenfield1'TYPE_NOHTML);
$formoutput str_replace('{param}'"$hiddenfield1"$formoutput); 

Then you can use {param} in custom output.

if you don't want to use custom output then add a custom question with php code:
PHP Code:

$answer '<input type="text" readonly="readonly" id="q_' $formbit[id] . '" name="' $formbit[id] . '" value="' $hiddenfield1 '" />'


I'm using this one my site but when a member tries to create the form with a username that contains opening characters such as the username #93forever they get an error...

"Error, this form needs a username."


Any idea how to fix this so that the system recognizes characters?

SilverBoy 04-06-2012 09:25 AM

I just installed this great product, and I have a Q, How I can add a forum drop-down list as an answer for multi-choice drop-down type? I just want it to know the favorites forums to my users.

blind-eddie 04-06-2012 10:14 AM

When adding new question select "Dropdown Select"....:p

SilverBoy 04-06-2012 11:29 AM

Thanks blind-eddie but how I can get the forums list automatically?

SilverBoy 04-06-2012 01:02 PM

As I said before I want to make multi selection from that drop-down list.

blind-eddie 04-07-2012 02:17 AM

You mean a drop down with dropdowns at each forum name to show sub-forums and to be added automatically?
I can't see that happening with this modification.
You would have to add each forum name you want added to the drop down selection.

If you want multiple dropdowns within that drop down you will have to hard code it to get that to work.

Good Luck....

SilverBoy 04-07-2012 02:38 AM

Yes I mean that and I know it is not built in in the hack :)
BTW I'm looking for a way to add drop-down list with multi-selection not only one selection at time.

Thanks in advance.

SilverBoy 04-20-2012 11:15 PM

I have some user groups in my forum that all posts of them goes to moderation queue, so how I can make threads created by forms goes to moderation queue if the user behind one of that user groups??? (the are primary groups and some user effected by some groups because of infraction system).


All times are GMT. The time now is 07:10 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.13504 seconds
  • Memory Usage 1,923KB
  • 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
  • (4)bbcode_code_printable
  • (2)bbcode_html_printable
  • (10)bbcode_php_printable
  • (8)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete