Elxis CMS Forum
Extensions => Bots and plugins => Topic started by: datahell on March 30, 2017, 23:59:09
-
I just released a free form generation plugin for Elxis. With AnyForm you can create really ANY standard form as it uses Elxis Form library in the backend. i am sure many people will love it.
You can download AnyForm plugin (https://www.elxis.net/edc/miscellaneous/142.html) from EDC.
More information tomorrow.
-
Great news, great plugin! Congratulations !!!
-
Really great and complete extension!
-
Awesome!
-
Plugin AnyForm updated to version 1.2
I would like to make a general presentation of the plugin as I haven't done so yet. If you have any questions you can reply below.
Most important features
- With AnyForm you can create ANY form.
- It uses Elxis form library in the backend.
- It supports 43 different input field types (select, text, radio, checkbox, textarea, etc).
- It supports fieldsets and tabs
- Input elements and all other form details are declared in an XML file with simple syntax even for newbies.
- Forms are multilingual.
- You can choose the submitted form data to be send to one or more email addresses, and/or saved in database, and/or saved in a text file.
- There is option to save both successful and unsuccessful submission attempts to Elxis logs folder (log rotation is also supported).
- HTML is generated automatically, you dont need to have programming skills.
- CSS and required Javascript is applied automatically.
- Form validation is done automatically.
- You can customize the generated forms and input fields.
- Supports Dynamic form loading (a trick by me). On a single form integration you can load dynamically unlimited different forms.
- There is option to change integration article's title to the form's title automatically.
- The design is responsive and forms are mobile friendly.
- Extended users documentation (24 pages in English) is available for licensed customers (read License below)
- About 20 keywords are supported (automatic values for input items with dynamic data). Examples: {TOMORROW}, {FIRSTNAME}, {NEXTMONTH}
Download AnyForm for free from EDC (https://www.elxis.net/edc/miscellaneous/142.html).
Examples
A few example of how you declare form items in XML files.
A text input field:
<item type="text" name="name" label="FIRSTNAME" default="{FIRSTNAME}" tip="Please write your name"></item>
A date picker:
<item type="date" name="date" label="DATE" required="1" default="{TOMORROW}" tip="" />
An "I am not a robot" captcha field:
<item type="norobot" name="notrobot" label="" default="" tip="" />
License
Plugin AnyForm is free. Forms generated by AnyForm display a small copyright note at the bottom. This is the only reward for Ioannis Sannos, the developer of AnyForm, for giving you this plugin for free. If you don't want to display this copyright you can purchase a license to remove it (https://www.isopensource.com/shop/software/11.html). By purchasing a copyright removal license you also get extended documentation for AnyForm plugin written by Ioannis Sannos.
Copyright removal and documentation by Is Open Source (https://www.isopensource.com/shop/software/11.html)
-
Hi datahell,
with ANYFORM, is it possible to add an upload button to allow user to attach a file to their submission?
-
It is possible but now it is not supported, mostly for security reasons.
-
Do you have any advice on how I could allow users to upload a document with their form?
I tried using Professional Form Manager but it's not compatible with the latest version of Elxis.
If AnyForm is not an option either, are there any other options?
Thanks for any advice you can give!
-
AnyForm updated to version 2.1. From this version AnyForm supports generating Image and File upload fields. After clicking submit the files/images get uploaded in folder media/anyform/ and also a download link is sent to the form's recipient email. This link is protected, if the site guest also gets the email there is no download link for him. Except from file uploads version 2.1 sends beautiful HTML e-mails.
Download/Update AnyForm 2.1 for free from EDC (https://www.elxis.net/edc/miscellaneous/142.html)
-
Great update! Congratulations once again !!!
-
Μπράβο Γιάννη! Πολύ καλή δουλειά!
-
Thank you guys. If I find some time I will improve it even more.
-
This is a great plugin with a great improvement in the new version. If we choose to store submissions to the database, how do we access/view the submissions afterwards? Is it possible via Elxis or only via directly accessing the SQL database.
-
Both options are possible. However the Elxis option requires to develop a special module or component in order to read the database entries, and maybe even edit/delete them. For now there is no such extension available. So, the working solution you have right now is PHPMyAdmin.
-
Ok, thanks!
Is there any way to make any of these form items visible in the automatic email: 3.37 note, 3.38 info, 3.39 custom, 3.40 html
What I would love to do is add some custom HTML that appears in the email.
-
These type of elements do not contain user data. Their role is to provide visual aid to the person that fills-in the form. So, they are not been displayed in the e-mail, neither get saved in an other way (file/database). However what you ask can be done but needs plugin modification.
-
Ah ok. I thought of a different solution: Display the custom HTML as the "onsuccess" message in the page. This is working fine except... users need to scroll down to the form location on the page to see the message. Is there a way to scroll the user automatically to the success message when the page refreshes? I tried a few javascript solutions but they don't work unfortunately.
-
Yes, it can be done. Follow my instructions.
Open your form's XML and find the "onsuccess" part. There I guess you have some HTML content inside some tags. Add an ID attribute to any of these tags (preferable the first one) to "anyfsucmsg".
Example:
<onsuccess><![CDATA[
<h3 id="anyfsucmsg">Success!</h3>
<p class="anyf_success">This is a sample text...</p>]]>
</onsuccess>
Save the XML.
Now, go and open your template's index.php file and put the code below anywhere (prefer the top section before the starting the "html").
$js = 'if (document.getElementById(\'anyfsucmsg\')) { document.getElementById(\'anyfsucmsg\').scrollIntoView(); }';
eFactory::getDocument()->addNativeDocReady($js);
That's it.
Explanation: The code above after the page gets completely loaded it searches for an element with id "anyfsucmsg". If it find it it scrolls down the user to that element.
I didn't tested it, test it. I guess it will work fine. Off course you can rename "anyfsucmsg" to anything you want.
-
Beautiful solution! This works on a test installation using the FIVE template. It doesn't work on a production site - do you know if there are any dependencies, e.g. a particular version of Jquery?
If I figure out through troubleshooting, I'll post here. Thanks for this.
-
The code I wrote you doesn't use jQuery but native javascript (Elxis 5.x method "addNativeDocReady"). Requires Elxis 5.x, don't try it on Elxis 4.x. So except from Elxis version has no other dependency.
It should work on any template, and even on any other type of extension. If it doesn't work then make sure you have put the code correctly, and if it doesn't work again check if it conflicts with an other page scroll on the same page. A lin to the page is required for further assistance.
-
Ok, thanks!
I just noticed a slight discrepancy between the Anyform manual and the sample form, regarding the "I am not a Robot" verification:
Manual: <item type="norobot" name="norobot" label="" default="" tip=""></item>
Sample Form: <item type="norobot" name="notrobot" label="" default="" tip="" />
Manual: name is norobot, there is a closing tag
Sample: name is notrobot and the tag is self-closing.
I don't know if this is important.
-
They are the same. It is an other way of writing the same thing.
<tag></tag> is equivalent to <tag />
-
Good morning
Working with Anyform version 2.1 on a localhost Elxis 5.3 rev2452 installation and setting in sample.xml file form as action "database" following the example of the documentantion, everything works fine and the submitted form data are saved into table elx_sample. But when I put into form an <item type="openfieldset" /> and at the end i close it with <item type="closefieldset" /> like below
<items>
<item type="openfieldset" label="PERSONAL_INFORMATION" />
<item type="text" name="name" label="FIRSTNAME" required="1" default="{FIRSTNAME}" tip=""></item>
<item type="text" name="surname" label="LASTNAME" required="1" default="{LASTNAME}" tip=""></item>
<item type="range" name="age" label="AGE" first="0" last="120" step="1" default="30" tip=""></item>
<item type="closefieldset" />
<item type="norobot" name="notrobot" label="" default="" tip="" />
<item type="button" name="sbt" label="" default="SUBMIT" button_type="submit" fieldboxclass="" />
</items>
then submitting the form I get the following error:
ERROR in file C:\apachefriends\htdocs\elxis53\includes\libraries\elxis\database\statement.class.php line 41
Uncaught PDOException: SQLSTATE[21S01]: Insert value list does not match column list: 1136 Column count doesn't match value count at row 1 in C:\apachefriends\htdocs\elxis53\includes\libraries\elxis\database\statement.class.php:41
Please have it in mind for a next update.
-
There is nothing wrong in AnyForm. Your database table should match XML items except from the items types listed below:
openfieldset, opentab, closetab, openrow, closerow, button, html, custom, note, info, opentoolbar, closetoolbar, starttabs, endtabs, norobot
There is one exception: The database table should contain a column for item type "closefieldset" if such an item exists in XML.
So your table should have these columns: id, firstname, lastname, age, cf (you can name your columns whatever you want)
-
Thank you for the additional information on subject. I did it as you suggest and it works fine.