Simple Forms [Paid] [Deleted]

Go to sleep, you deserve it (y)
And in the morning when you get time, please just show me how to put this arround conditionals if this field is not filled to not show in post, and if it is filled with answer to show up in post.
Thank you...

{$fields.Lokacija_ribolova.title}
{$fields.Lokacija_ribolova.value}


Code:
<xen:if is="{$fields.fieldname.value} == x">
This content will show if value is x
<xen:else />
This content will show if the value is anything but x
</xen:if>
It's very simple:
Code:
<xen:if is="{$fields.Lokacija_ribolova.value} != ''">
{$fields.Lokacija_ribolova.title}: {$fields.Lokacija_ribolova.value}
</xen:if>
 
It's very simple:
Code:
<xen:if is="{$fields.Lokacija_ribolova.value} != ''">
{$fields.Lokacija_ribolova.title}: {$fields.Lokacija_ribolova.value}
</xen:if>

Excellent! It is working.
But another bug...
If you have many not filled fields and after that some filled fields, you have a big gap in post between answered fields

1_zps95a9333f.png


screenshot_zps1189b5c4.png
 
yes! :( also very need fix it
Don't worry, we haven't forgotten about you ;). Once our 1.4 compatibility issues are fixed it will be released.
Excellent! It is working.
But another bug...
If you have many not filled fields and after that some filled fields, you have a big gap in post between answered fields

1_zps95a9333f.png


screenshot_zps1189b5c4.png
This is why the work-around can be a little problematic. What you have to do in this case is put the spacing inside of the template conditional. So if you have multiple conditionals (one after another), setting up like this works well:
Code:
<xen:if is="{$fields.Lokacija_ribolova.value} != ''">{$fields.Lokacija_ribolova.title}: {$fields.Lokacija_ribolova.value}
</xen:if><xen:if is="{$fields.Lokacija_ribolova.value} != ''">{$fields.Lokacija_ribolova.title}: {$fields.Lokacija_ribolova.value}
</xen:if><xen:if is="{$fields.Lokacija_ribolova.value} != ''">{$fields.Lokacija_ribolova.title}: {$fields.Lokacija_ribolova.value}
</xen:if>
The line-break in the template field = a gap between fields. So in order to fix that you would put the line-break INSIDE the conditional like above and keep the next conditional on the same line. It can be a little confusing, that's why I said this work-around is a bit difficult.
 
It is working (y)

Code:
[B]{$fields.Lokacija_ribolova.title}[/B]
{$fields.Lokacija_ribolova.value}

[B]{$fields.Izvjestaj.title}[/B]
{$fields.Izvjestaj.value}

<xen:if is="{$fields.Datum.value} != ''">
[B]{$fields.Datum.title}[/B]
{$fields.Datum.value}
</xen:if><xen:if is="{$fields.Ulov.value} != ''">
[B]{$fields.Ulov.title}[/B]
{$fields.Ulov.value}

</xen:if><xen:if is="{$fields.Slike.value} != ''">
[B]{$fields.Slike.title}[/B]
[center]{$fields.Slike.value}[/center]

</xen:if><xen:if is="{$fields.Mapa.value} != ''">
[B]{$fields.Mapa.title}[/B]
[center]{$fields.Mapa.value}[/center]
</xen:if><xen:if is="{$fields.Mamac.value} != ''">
[B]{$fields.Mamac.title}[/B]
{$fields.Mamac.value}
</xen:if><xen:if is="{$fields.Oprema.value} != ''">
[B]{$fields.Oprema.title}[/B]
{$fields.Oprema.value}
</xen:if><xen:if is="{$fields.Sistem.value} != ''">
[B]{$fields.Sistem.title}[/B]
{$fields.Sistem.value}
</xen:if><xen:if is="{$fields.Dubina.value} != ''">
[B]{$fields.Dubina.title}[/B]
{$fields.Dubina.value}
</xen:if><xen:if is="{$fields.Vrijeme.value} != ''">
[B]{$fields.Vrijeme.title}[/B]
{$fields.Vrijeme.value}
</xen:if><xen:if is="{$fields.Mjesec.value} != ''">
[B]{$fields.Mjesec.title}[/B]
{$fields.Mjesec.value}</xen:if>
 
It is working (y)

Code:
[B]{$fields.Lokacija_ribolova.title}[/B]
{$fields.Lokacija_ribolova.value}

[B]{$fields.Izvjestaj.title}[/B]
{$fields.Izvjestaj.value}

<xen:if is="{$fields.Datum.value} != ''">
[B]{$fields.Datum.title}[/B]
{$fields.Datum.value}
</xen:if><xen:if is="{$fields.Ulov.value} != ''">
[B]{$fields.Ulov.title}[/B]
{$fields.Ulov.value}

</xen:if><xen:if is="{$fields.Slike.value} != ''">
[B]{$fields.Slike.title}[/B]
[center]{$fields.Slike.value}[/center]

</xen:if><xen:if is="{$fields.Mapa.value} != ''">
[B]{$fields.Mapa.title}[/B]
[center]{$fields.Mapa.value}[/center]
</xen:if><xen:if is="{$fields.Mamac.value} != ''">
[B]{$fields.Mamac.title}[/B]
{$fields.Mamac.value}
</xen:if><xen:if is="{$fields.Oprema.value} != ''">
[B]{$fields.Oprema.title}[/B]
{$fields.Oprema.value}
</xen:if><xen:if is="{$fields.Sistem.value} != ''">
[B]{$fields.Sistem.title}[/B]
{$fields.Sistem.value}
</xen:if><xen:if is="{$fields.Dubina.value} != ''">
[B]{$fields.Dubina.title}[/B]
{$fields.Dubina.value}
</xen:if><xen:if is="{$fields.Vrijeme.value} != ''">
[B]{$fields.Vrijeme.title}[/B]
{$fields.Vrijeme.value}
</xen:if><xen:if is="{$fields.Mjesec.value} != ''">
[B]{$fields.Mjesec.title}[/B]
{$fields.Mjesec.value}</xen:if>
I'm glad, in our next release you can leave the template blank and it will hide fields properly if you need it too :)
 
Does there happen to be a way to add a 'Placeholder' value to Drop-down fields - would be nice :)?

I'm also probably being stupid here, but is there a way to center fields? Currently I'm using Post Text to provide headings to a number of sections with fields under them, however if I center the 'Post Text' its not actual centered to the fields and thus looks untidy.
 
Last edited:
Does there happen to be a way to add a 'Placeholder' value to Drop-down fields - would be nice :)?

I'm also probably being stupid here, but is there a way to center fields? Currently I'm using Post Text to provide headings to a number of sections with fields under them, however if I center the 'Post Text' its not actual centered to the fields and thus looks untidy.
Hello malonik,

As of this moment the placeholder field does not work for select field types (drop-downs). Typically placeholders are used for input fields only. In the future we will see if there is a way to specify a default select option that doesn't break validation, but for now it's not available.

As for pre and post text, I'm simply using the default XenForo styles for this. That's how most of the forms in XenForo look, but can you post a screenshot of what you mean? It might be best to simply not center it.
 
Hello malonik,

As of this moment the placeholder field does not work for select field types (drop-downs). Typically placeholders are used for input fields only. In the future we will see if there is a way to specify a default select option that doesn't break validation, but for now it's not available.

As for pre and post text, I'm simply using the default XenForo styles for this. That's how most of the forms in XenForo look, but can you post a screenshot of what you mean? It might be best to simply not center it.

Thanks for the reply - as you said I think a picture says 1000 words :). As you can see below, the 'Personal Information' doesn't seem right because the Fields are not being centered themselves. Trying to separate sections with headings and making it neat is a little difficult.
 

Attachments

  • Capture.webp
    Capture.webp
    9.8 KB · Views: 5
Thanks for the reply - as you said I think a picture says 1000 words :). As you can see below, the 'Personal Information' doesn't seem right because the Fields are not being centered themselves. Trying to separate sections with headings and making it neat is a little difficult.
That's definitely centered, but the labels for the forms are next to the inputs so the text is centering based on the width of the page as opposed to the width of the input field. This is again my personal opinion, but I think it would look more out of place to have it centered only based off the field input size. Which is random based on mobile screen sizes.
 
hi,

for the form destinations>thread>title,

is it possible to extract a certain number of characters from the text submitted through the form to use as the title of the thread?

for example, i only have one field for the form and for the title i want to display 100 characters from the content submitted and add "..." . for the thread template it would be the full content submitted.
 
hi,

for the form destinations>thread>title,

is it possible to extract a certain number of characters from the text submitted through the form to use as the title of the thread?

for example, i only have one field for the form and for the title i want to display 100 characters from the content submitted and add "..." . for the thread template it would be the full content submitted.
You would more than likely have to write a function to truncate the value of the field you've created. There is no way to do this currently.
 
@tyihao

Apparently I was wrong, you can try something like this:

{xen:helper wordtrim, $fields.first_name.value, 10}

Replace "first_name" with the ID of the field you have.
 
I've been getting the following server errors in my logs when people submit applications.

Code:
ErrorException: Undefined index: status - library/LiquidPro/SimpleForms/Option/LicenseKey.php:226
Code:
#0 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/Option/LicenseKey.php(226): XenForo_Application::handlePhpError(8, 'Undefined index...', '/home/itsnotch/...', 226, Array)
#1 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/Option/LicenseKey.php(42): LiquidPro_SimpleForms_Option_LicenseKey::_checkLicense('LP-408e5c1f4e', '=03OicDM4ADNxAj...')
#2 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/EventListener.php(123): LiquidPro_SimpleForms_Option_LicenseKey::VerifyLicense('LP-408e5c1f4e')
#3 [internal function]: LiquidPro_SimpleForms_EventListener::ControllerPreDispatch(Object(LiquidPro_SimpleForms_ControllerPublic_Form), 'Save', 'LiquidPro_Simpl...')
#4 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/CodeEvent.php(58): call_user_func_array(Array, Array)
#5 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/Controller.php(311): XenForo_CodeEvent::fire('controller_pre_...', Array, 'LiquidPro_Simpl...')
#6 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/FrontController.php(346): XenForo_Controller->preDispatch('Save', 'LiquidPro_Simpl...')
#7 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#8 /home/itsnotch/public_html/vicegamers/forums/index.php(13): XenForo_FrontController->run()
Code:
array(3) {
["url"] => string(43) "http://www.vicegamers.com/forums/forms/save"
["_GET"] => array(0) {
}
["_POST"] => array(7) {
["fields"] => array(11) {
[12] => string(3) "ps3"
[13] => string(10) "Gangstarr4"
[14] => string(12) "FrostbyteXV "
[15] => string(17) "Central - Chicago"
[16] => string(3) "Yes"
[17] => string(397) "Looking for mature players to hang around and get money with. I want to feel the vice city vibe while doing crew activities and getting involved.. I have ran a crew with 300 Members and been a commissioner in another that has had high numbers , also I ran a smaller crew that was on the leaderboards. I am a active gamer when I'm not on tour or performing. I am excited to be apart of this Family "
[18] => string(2) "18"
[19] => string(2) "10"
[20] => string(1) "7"
[21] => string(2) "10"
[22] => string(2) "10"
}
["fields_shown"] => array(11) {
[0] => string(2) "12"
[1] => string(2) "13"
[2] => string(2) "14"
[3] => string(2) "15"
[4] => string(2) "16"
[5] => string(2) "17"
[6] => string(2) "18"
[7] => string(2) "19"
[8] => string(2) "20"
[9] => string(2) "21"
[10] => string(2) "22"
}
["form_id"] => string(1) "1"
["_xfRequestUri"] => string(51) "/forums/forms/gta-online-vccm-application.1/respond"
["_xfNoRedirect"] => string(1) "1"
["_xfToken"] => string(8) "********"
["_xfResponseType"] => string(4) "json"
}
}
 
I've been getting the following server errors in my logs when people submit applications.

Code:
ErrorException: Undefined index: status - library/LiquidPro/SimpleForms/Option/LicenseKey.php:226
Code:
#0 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/Option/LicenseKey.php(226): XenForo_Application::handlePhpError(8, 'Undefined index...', '/home/itsnotch/...', 226, Array)
#1 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/Option/LicenseKey.php(42): LiquidPro_SimpleForms_Option_LicenseKey::_checkLicense('LP-408e5c1f4e', '=03OicDM4ADNxAj...')
#2 /home/itsnotch/public_html/vicegamers/forums/library/LiquidPro/SimpleForms/EventListener.php(123): LiquidPro_SimpleForms_Option_LicenseKey::VerifyLicense('LP-408e5c1f4e')
#3 [internal function]: LiquidPro_SimpleForms_EventListener::ControllerPreDispatch(Object(LiquidPro_SimpleForms_ControllerPublic_Form), 'Save', 'LiquidPro_Simpl...')
#4 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/CodeEvent.php(58): call_user_func_array(Array, Array)
#5 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/Controller.php(311): XenForo_CodeEvent::fire('controller_pre_...', Array, 'LiquidPro_Simpl...')
#6 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/FrontController.php(346): XenForo_Controller->preDispatch('Save', 'LiquidPro_Simpl...')
#7 /home/itsnotch/public_html/vicegamers/forums/library/XenForo/FrontController.php(134): XenForo_FrontController->dispatch(Object(XenForo_RouteMatch))
#8 /home/itsnotch/public_html/vicegamers/forums/index.php(13): XenForo_FrontController->run()
Code:
array(3) {
["url"] => string(43) "http://www.vicegamers.com/forums/forms/save"
["_GET"] => array(0) {
}
["_POST"] => array(7) {
["fields"] => array(11) {
[12] => string(3) "ps3"
[13] => string(10) "Gangstarr4"
[14] => string(12) "FrostbyteXV "
[15] => string(17) "Central - Chicago"
[16] => string(3) "Yes"
[17] => string(397) "Looking for mature players to hang around and get money with. I want to feel the vice city vibe while doing crew activities and getting involved.. I have ran a crew with 300 Members and been a commissioner in another that has had high numbers , also I ran a smaller crew that was on the leaderboards. I am a active gamer when I'm not on tour or performing. I am excited to be apart of this Family "
[18] => string(2) "18"
[19] => string(2) "10"
[20] => string(1) "7"
[21] => string(2) "10"
[22] => string(2) "10"
}
["fields_shown"] => array(11) {
[0] => string(2) "12"
[1] => string(2) "13"
[2] => string(2) "14"
[3] => string(2) "15"
[4] => string(2) "16"
[5] => string(2) "17"
[6] => string(2) "18"
[7] => string(2) "19"
[8] => string(2) "20"
[9] => string(2) "21"
[10] => string(2) "22"
}
["form_id"] => string(1) "1"
["_xfRequestUri"] => string(51) "/forums/forms/gta-online-vccm-application.1/respond"
["_xfNoRedirect"] => string(1) "1"
["_xfToken"] => string(8) "********"
["_xfResponseType"] => string(4) "json"
}
}
An email was sent out a few weeks ago with a fix for this. If you have not received the email or cannot find it, you can simply re-download 2.1.4 and replace your files (no upgrade of the addon is necessary). Let me know if you have further issues in a support ticket :).
 
hi John! how to make so that after submit form, new thread it was created by the closed? very need!
This has been added to Simple Forms 2.1.5 @olegus-78
Just noticed a very minor error - on the ratings form (default) , the first option radio button is slightly cut off on the left hand side (checked in Chrome and Safari)...
Not a major issue just looks bit odd.
Hey @jayramfootball this should have been included in the release. Let me know if it is not.
OK thanks @LP-John

Couple of things I have noticed in 2.1.4 ... not sure they are bugs (don't thinks so) but just some feedback...
When the 'Hide Empty Fields' is selected within a form destination the fields are still shown in a post (with a missing value where the field would have been).. as below...where it has included the field name 'Wenger...' and the 'out of 10' which is output as part of a ratings field.

View attachment 80141

Also, in form destinations, where it you disable a field within a form the template for the form destination still shows a blank line where that field would have been... it would be GREAT if by disabling a field the form destination field would ignore the entry completely (it would save having to delete the form destination template line and have it exactly match the enabled fields all the time...

Hope that makes sense.. cheers

Great add on(y)
This has also been fixed in 2.1.5
The promotion seems to work, but it is totally random which usergroup they get promoted into!
Promotions should be working fine @jakew009 in 2.1.5
I am very pleased with this MOD. For so little money, excellent addon. (y)

Few questions...
  • Even if I check this field "Check this to hide fields that the user did not respond to." title of that fields is show up in post. Am I miss something?
  • How to simple make little more space between fields (when you open form that you want to fill in?

Suggestion
  • When field helper show up, could you make it that we can move it on screen, couse now is in right down corner and is hard to press links if you have many fields
Hey @Sunka, we've made the Field Helper draggable to assist you ;).
yes! :( also very need fix it
No worries, it's now fixed!
 
Top Bottom