News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Custom Form Mod

Started by live627, July 09, 2008, 10:24:44 PM

Previous topic - Next topic

tsmalmbe

Quote from: NeQo on January 02, 2009, 01:57:12 PM
Omg! did you read this topic? look at the top of this page to find the solution for this great mod.
Hint: it has something to do with "".... :P
Quote from: NeQo on January 02, 2009, 01:57:12 PM
Quote from: tsmalmbe on January 02, 2009, 07:01:34 AM
Anyway, default values do not seem to work, and if I mark something as required, the form does not submit regardless of if I put a value in the required field or not.

Omg! did you read this topic? look at the top of this page to find the solution for this great mod.
Hint: it has something to do with "".... :P

Yes. The required now works. But the default values do not.

required,default=(str)

makes it require, but does NOT print out "str" (or any other string, even tried quoting).
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

tsmalmbe

Also, I would like to add a +1 on getting attachments as a field option.
..:: http://www.kontrollrummet.com - Studio och musik ::.. RSS?

fasterthanyours

#402
Ok I'm banging my head.

I modded the install for 1.1.5 to install on all 1.1.X installs so I could get it to run on my 1.1.8 board.

Seems to be working ok and when I was done adding everything to the form I hit save and it just takes me back to the edit form page.

It doesn't list my form when I got to ?action=form

I'm not getting any errors as of yet.

EDIT:I checked the log and I do have the following over and over again.
http://www.charlestonreefers.org/forum/index.php
8: Undefined index: boardViewersClickable
File: /home/minfinge/public_html/charlest/forum/Sources/BoardIndex.php
Line: 345


Someone please tell me what might be going on.

Enders

there is some kind of bugs... When I edit permissions in admin > members > permissions .... it unchecks them in custom forms?

fasterthanyours

I figure it out.  What was going on.  I'm not find this mod very user friendly from a back-end admin stand point.

However.  You name the form and such and from what I can tell don't type anything in the normal window.

You have to add entries into the form below that.

Going to take a while for me to test my form as I have about 30 things I need on it.

olifa

do you have any new information when you are going to release the new version of this mod so the bug with the
[img]http://http://urlofapicture[/img]  disappears?^^

I'm using smf 1.1.x and this mod is so great! I use it for a lot of different purposes! =)

Garou

I'm not the author of the mod but I have given some support on the mod as Ive become more familiar with it. I'm also not familiar with that error.

When, where, and how do you arrive at that issue? If you point me in the right direction I might be able to come up with a fix for it.

fasterthanyours

#407
Ok I give up.  I'm really banging my head.

I just made this huge form with like 30 fields and I can't get a single one of them to display in the post after I hit submit.

I'm not even getting the Subject to appear the message is completely blank.

What the heck am I doing wrong?

Even with out the Custom Template field filled in, it still doesn't work.

Enders

Is there a way to make a form that will post it under one topic instead of creating a new topic?

Garou

Enders, at the moment no. Each post goes to a new thread but its been talked about as a possibility for a future release to have the option of posting to one topic.

As for the permissions, Custom Forms makes its own permissions and the two are not supposed to be connected. You set the Form up as for who can see that and you use the forum permissions to see who can see the board. However is a person has access to the form they can fill it out and post to the board from the form even if they don't have permission to post. The form ignores the board permissions.

fasterthanyours, I'm going to see if I cant get the form to work right for 1.1.8 and the RC. I have permission from LHVWB to package it up and post it if I can get it to work. :)

Nathaniel

Just to formalize this. ;)

Garou is now an 'Additional Author' for the Custom Form Mod, so they should be able to help with some support and updating this mod to work with the newer versions of SMF.

Unfortunately I don't really have time at the moment to work on updating and supporting this mod. Although I have plans to rewrite this mod from scratch with all of the functionality which has been requested (for SMF 2 final - when it comes out), but that probably won't happen for a while (maybe even until the end of the year) due to my time constraints.

Sorry that I haven't really responded to any support requests in this topic, they have been building and I really haven't had the time. :/
SMF Friend (Former Support Specialist) | SimplePortal Developer
My SMF Mods | SimplePortal

"Quis custodiet ipsos custodes?" - Who will Guard the Guards?

Please don't send me ANY support related PMs. I will just delete them.

fasterthanyours

#411
Quote from: Garou on February 20, 2009, 05:53:14 AM
fasterthanyours, I'm going to see if I cant get the form to work right for 1.1.8 and the RC. I have permission from LHVWB to package it up and post it if I can get it to work. :)

To my knowledge not that much changed between 1.1.5. and 1.1.8 except security.

Please tell me that it's not because I'm running 1.1.8 that it won't push the variables through???

LHVWB, good luck with the SMF2 stuff.  I spent hours trying to get a mod that I took over to get to work in SMF2.  Unfortunately I can't post my mod on SMF's site because they don't approve of it ;)

Here's the 2 files I modified to get it to install.

Garou

#412
Yeah getting mods approved can be hard at times but remember that they are very busy right now between all the mods being updated for 1.1.8 and the RC. Have you heard back from them at all yet?

As for the mod I just remembered that there is a version that LHVWB posted but its not on the mod page. http://www.simplemachines.org/community/index.php?topic=248871.msg1770153#msg1770153 and the DL is http://www.simplemachines.org/community/index.php?action=dlattach;topic=248871.0;attach=73540.

Ive been able to get this to install on 1.1.8 without issue and I'm currently testing to see if there are any other errors. It does have the required fields issue yet, however that has been addressed and will be fixed in the next update. http://www.simplemachines.org/community/index.php?topic=248871.msg1810128#msg1810128

tsmalmbe, at present you cant add the default values with the required option. It might be possible in the future, we will have to look at that.

There have been other suggestions made that we'll look at as well but the priority now is to make sure it is all running the way it was intended, like it did in earlier versions.

I'm very much looking forward to the rewrite that LHVWB has planed, I know it will be great just like all the other projects hes been working on as well as this one. I'm even more happy that he is willing to let me help out with the mod in its current state.


Garou

#413
Mod updated for 1.1.8
CustomFormMod_v1.3_SMF1.1.x.zip.

Mod updated for 2.0 beta 4 and RC1
CustomFormMod_v1.3_SMF2.x.zip.

Garou

#414
I just went through every post in this thread and made a check list of all bugs and requests.

The requires fields bug has been addressed in the last update but I did find a different fix from another user that I will have to test out. I forgot about the Internet Explorer issue and didn't get it in there, that will be in my next update.

As for the requests some of them I should be able to work out but some will have to wait till the the rewrite LHVWB has planned, either because they are beyond my knowledge or they are just beyond what the existing code can handle without being entirely re-written. I will try to get as many in as I can though.

@ tsmalmbe, I got a better look at what you were asking about your required fields problem and its because you are entering conflicting options.

The default=(str) option is what is posted if the user doesn't fill out the field.
for example you ask  "What is your favorite color"? Then you set default=(red). If the user leaves the field blank then when the form is posted it will automatically post "red".

The required option forces the user to fill out the field.
So if the user doesn't fill out the field then the form pops back up telling them that they have to fill out the field. However when they do fill it out then the default=(str) is overridden because they did.

The two variables can not logically coexist. What result were you expecting to see? Perhaps we can find another way to do it.

As for the attachments, its on the request list and if possible we will add it in a future update.

@ Enders, that has been on LHVWB's to do list for a while now and Ive added it to mine, Id like to have that option for some of my boards as well, hopefully one of us can figure it out.

@ fasterthanyours, you are running into a syntax issue that is confusing the form output.
Quote from: Garou on December 22, 2008, 09:31:33 PM
It looks like MrMusic's Problem is solved.

The problem wasn't in the Mod but in the syntax of the questions asked.

The "title" for the questions works better when small case is used and there are no spaces. The "text" section is the way you want it to look in your form. Also in the Post output section, you need to format the form input to match the "title".

For instance if you want to use "Your Name" as a question you would need to format it as...

Title                                              your_name
Text                                              Your Name
Type                                             Text Box (String)
Extra Type Parameters                    required


Then in the Form Output section you would use
My name is: {your_name}

In the actual form people fill out you would see...
Your Name                                        Garou

Then when the message is posted to your board you would see...
My name is: Garou


fasterthanyours

#415
Garou,

Check you PM.

Well I was looking at my syntax again and I'm 99% I've got it correct.

Here's my form:
http://www.charlestonreefers.org/forum/index.php?action=form;id=1

My Form Output is the following just to test:
This is my problem: {problem}
Fresh: {Fresh}

I get nothing, not even the subject.

It's just not working.

Smoky "Rider" Blue

* SmokyBlue slides a coffee to Garou..

cheers!!  ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Garou

Thank ya Smoky  ;)

fasterthanyours, the screen shot you posted earlier was showing the syntax issue.
Even if your not trying to display the questions in the output it was being asked in the form and going to cause issues.

You have...
Title:Tank Size
Text:Tank Size in Gallons

It should be...
Title: tanksize or tank_size either should work
Text: Tank Size in Gallons
The Forum Output would be either {tanksize} or {tank_size} depending on which you use.

Title: Fresh
should be
Title: fresh
Fourm Output should be {fresh}

You have several instances of that type of mistake in the screen shot. The title just does not have to be that descriptive. The Text is what your users are actually going to see anyway. The Title is just a designator and only seen by you and should be short, no capitalization, and no spaces.

fasterthanyours

Quote from: Garou on February 21, 2009, 07:45:52 AM
The Title is just a designator and only seen by you and should be short, no capitalization, and no spaces.

And what copy of the instructions did you get? LOL

Seriously I didn't see any.  I'll fix all of them and try it again.

But the thing is, it's not even posting the subject, or even the normal text in the Output section.

I'll keep trying.

You get your PM?

yus786

Is this at all possible?

I need a form that has a built in lookup table for email addresses?

Example.

Say we have a drop down selection for Departments.

If the user selects Dept1, then the form should be posted to forum/thread 1
If the user selects Dept2, then the form should be posted to forum/thread 2


Is this possible?

Advertisement: