Jump to:

23371 Posts in 18161 Topics by 2865 members

General Questions

SilverStripe Forums » General Questions » User Defined Form - Error Creating Field

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1 2
Go to End
Author Topic: 3387 Views
  • rach999
    Avatar
    Community Member
    4 Posts

    User Defined Form - Error Creating Field Link to this post

    Hi,

    I am having trouble with my user defined form. I have the latest version of silverstripe and the user form. It installs fine but $UserDefinedForm appears in the editor when i create a new page and when i click on the form tab and try to create a new field i get this error 'Error Creatign Field'. I have looked through the forums for and answer without any luck. I changed my $form in my page.ss to $UserDefinedForm but still nothing.

    I noticed the link in the config files states this:

    <?php

    LeftAndMain::require_javascript('userforms/javascript/FieldEditor.js');
    LeftAndMain::require_css('userforms/css/FieldEditor.css');

    ?>

    BUT in the javascript file there is not FieldEditor.js only UserForm.js is this an error with the forms? This is all i coudl think of that would be the problem. I did change the name of the file but still nothing changed with my form. I really would love to get this working as I have been working on this form for weeks.

    Any help would be appreciated.

    Thanks

    Rachael

  • sfarinel
    Avatar
    Community Member
    1 Post

    Re: User Defined Form - Error Creating Field Link to this post

    i have the same exact problem.
    I am new to silverstripe an i just install the userforms module.
    and anytime i try to add a field i receive the "Error creating field" message.

    Please help

  • Willr
    Avatar
    Forum Moderator
    5489 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    Both of you could you please install firebug for firefox if you haven't already got it and then once installed use the 'Console' tab in firebug to look at the failed request (it should be red). If you click the down arrow you should see the full error message.

  • Patrick
    Avatar
    Community Member
    11 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    I have the same issue after updating the module due to a different issue (which I will post separately if the new version doesn't solve it).

    When loading the form page in the CMS admin, the firebug console shows this:
    ----------------start---------------------------------------
    $(this).sortable is not a function
    http://localhost/userforms/javascript/UserForm.js?m=1257146550
    Line 197

    (?) ()UserFo...7146550 (line 197)
    for newly matched elements nEls.each ()jquery...3908762 (line 126)
    each ()jquery...3908760 (line 745)
    each ()jquery...3908760 (line 138)
    run ()jquery...3908762 (line 125)
    checkQueue ()jquery...3908762 (line 151)

    update : function (event, ui) { UserFo...7146550 (line 197)
    ----------------end---------------------------------------

    Also, when selecting the text field and clicking on "Add", the console outputs the following:

    ----------------start---------------------------------------
    GET http://localhost/admin/EditForm/field/Fields/addfield?NewID=1&Type=EditableTextField
    500 Error: "Couldn't run query: SELECT MAX("Sort") FROM "EditableFormField" WHERE "ParentID" = '150' You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '"EditableFormField" WHERE "ParentID" = '150'' at line 1" at line 401 of C:\wamp\www\sapphire\core\model\MySQLDatabase.php
    ----------------end---------------------------------------

    Hope this helps.

    EDIT: I'm using SS 2.3.3 and this happens with the latest version of the module posted for download (0.2.1) and also with the latest trunk (r98906).

  • Patrick
    Avatar
    Community Member
    11 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    I'm guessing there is an issue with the update from 0.1 - I was able to get user defined forms to work by removing the module and deleting the tables (all the tables starting with "Editable" and with "UserDefinedForm"), running a /dev/build and reinstalling the latest version of the module.

  • Doverose
    Avatar
    Community Member
    8 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    I get this in Firebug:

    http://mydomain.com/admin/EditForm/field/Fields/addfield?NewID=1&Type=EditableTextField 404 Not Found

    http://mydomain.com/assets/base.js?m=1266081004 Line 554

    I tried installing the newest trunk and deleting the DB fields and rebuilding but just got even more errors

    I am running SS 2.3.6 but I have had this trouble when making forms other than in the default language

  • Willr
    Avatar
    Forum Moderator
    5489 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    You'll have to use Userforms 0.2 with SS 2.3. Userforms trunk is now 2.4 only I think.

  • SSadmin
    Avatar
    Community Member
    90 Posts

    Re: User Defined Form - Error Creating Field Link to this post

    i met the same problem with ss2.3.6 early verison with lastest userdefined form moduel. the firebug error was the same with Doverose.
    http://mydomain.com/admin/EditForm/field/Fields/addfield?NewID=1&Type=EditableTextField 404 cannot found.

    after several tries on different methods. i downloaded a new clean ss2.3.6 and userform v0.2.1, and not install through installer but manually configurated the _config file and .htcaccess file.

    Then i got everything works...feel so strange about that. i wonder its there too different sub version of 2.3.6 when silverstripe released the verison..
    My installer package was downloaded nearlly February 13th. my new .zip file of ss2.3.6 was downloaded at 21th of February.
    or is there some configuration things missing when choosing installer setup or unzip core packages.

    Any Suggestions?
    Thanks lots..

    3387 Views
Page: 1 2
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.