Forum Replies Created

Viewing 15 replies - 1 through 15 (of 56 total)
  • Thread Starter Karen Turner

    (@karen-turner)

    I have been working on this problem all day.

    I see now, that the “novalidate” is added to the form by the jquery validate program. This is to stop browser default validating.

    I have removed all the jquery scripts for validation, all the jquery rules and messages and just have participants database and the HTML5 plugin. I have made sure that the fields that are required, have the attribute set to required.

    The form does not validate client-side.

    If I add a message to the field in the message box on manage database fields, this shows up when the form is submitted.
    The problem is that the field that has not been filled in is not highlighted, so it is hard to find.

    I have tried a fresh installation of participants database on another site, with the HTML5 plugin. This form does validate client side.
    However, if I add jquery script and validation, it does not work and no validation occurs. jquery validation does work on a test form that I put on another page.

    I am afraid that our website is virtually unusable now, as the form depends on a lot of conditional validation. I am feeling very disheartened, as the site has used participants database successfully for 5 or 6 years and we have built a large database.
    I don’t think I have enough knowledge to try anything else.

    Thread Starter Karen Turner

    (@karen-turner)

    I am sorry, I don’t think I can be explaining very well. I have set the field attributes to required as you describe.

    I dont know where the “novalidate” is set, I assumed it must be in the participants database:

    <form method=”post” enctype=”multipart/form-data” autocomplete=”off” action=”/new-client/applicant-one-new/?pid=XXXX” novalidate=”novalidate”>

    where ever it sets all these attributes for the multi form?

    So, when I enter data on the multi form of participants database, with no custom validation and the HTML5 plugin activated, it is not validating the fields set with the required attribute until the form is submitted. The result is the same as when the HTML5 plugin is deactivated.

    So, I think I am wondering if the “novalidate” has been added to the multiform in participants database at any point?

    Thread Starter Karen Turner

    (@karen-turner)

    But, if I remove any custom code and remove the jquery validate plugin, then set the ‘required’ field in the ‘Manage Database Fields’ on an element, the form still does not validate until submitted. So, the required field is not flagged as required, until the form is submitted. Then, the error is displayed at the side of the form, not in the field that has the error.

    This is the same behavior whether the HTML5 plugin is activated or deactivated.

    So, I am saying that the HTML5 plugin is no longer having any effect.

    I notice on inspection, that the opening form tag is
    <form method=”post” enctype=”multipart/form-data” autocomplete=”off” action=”/new-client/applicant-one-new/?pid=XXXX” novalidate=”novalidate”>

    I am not sure the novalidate=”novalidate” is correct.

    So, I think I need to get the basic form validation working before I re-add the jquery validation on top.
    Do you have any ideas why I could be having this problem now.

    Thread Starter Karen Turner

    (@karen-turner)

    I have checked that the jquery validation script is getting loaded and working. I did this by adding another form to the site with rules. The client-side validation works on this form correctly, showing that the script is being added and works.

    The odd thing is that the client-side validation is not working on the participants database forms as expected with just the HTML5 plugin and all the custom code removed, with the flags set as ‘required’ in the ‘Manage Database Fields’. I believe that if you have the HTML5 plugin, the form should automatically use client-side validation?

    I can see from the web developer tools that the init code is being added.

    Thread Starter Karen Turner

    (@karen-turner)

    On The https://xnau.com/product/html5-form-elements/ description page it says:

    If you’ve got some Javascript skills, this plugin works seamlessly with popular jQuery validation plugins to give your users a complete client-side validation experience. Using jQuery-based client-side forms validation makes your forms easier and faster to fill out and is the only way to achieve conditional validation where some fields are only validated given the state of other fields.

    Is is exactly what we needed as some fields are conditionally required based on the state of another field.

    So I added the jQuery plugin script and wrote all the rules and messages for the fields. This used to be working perfectly.

    Now, for some reason, I am getting no client-side validation. The fields that are marked as required, are only flagged as required when the form is submitted.

    I have tried removing all the JQuery script and rules and messages to leave participant database with no conditional rules. But still, the ‘required fields’, are not being validated client side.

    I simply cant think what to do. I am in the process of rolling back the participants database plugin and getting the HTML5 plugin back from backup.
    I assume that the client side validation works fine for you on a multi-form, so I’m truly lost here.

    I cant understand why it was working, but sadly, I don’t know exactly when it stopped.

    Thread Starter Karen Turner

    (@karen-turner)

    The client-side validation is no longer working even for the fields that I have set the required attribute.

    The entire script that I set up
    $(document).ready(function() {
    $( “form” ).validate({
    rules: {
    .
    .
    .
    messages: {
    .
    .
    .
    }
    });
    });

    is just being ignored.
    All of these rules and messages were operational previously.
    I have tried rolling back participants database. I dont think I can roll back the HTLM5 plugin?

    I have tried creating a separate form on the website, with validation to check that the jquery is being loaded correctly and the client-side validation works correctly on that form.

    For the participants database form validation, I have always had
    $( “form” ).validate({
    I cannot see that the form has an id to use.I am using the multi form. Has this been changed?

    This is a desperate situation. Please can you think of anything else, or provide me with the old HTML5 plugin to try?
    Thanks

    I have now worked on a better solution:
    1.Goto
    https://code.google.com/archive/p/simplemodal/downloads
    download jquery.simplemodel.1.4.4.min.js
    rename it jquery.simplemodel.1.4.3.min.js

    overwrite it in your WP plugins folder ajax-event-calander/js
    2. Goto
    https://plugins.jquery.com/jgrowl/
    download version 1.3.0
    unzip and copy jquery.jgrowl.min.js into WP plugins folder ajax-event-calander/js
    overwriting old version

    These two updates were written by the plugin author, but I guess he didn’t update the plugin with them, before stopping his support.
    For some reason still need the ‘Enable jQuery Migrate Helper’, as the calander crashes without. Will let you know if I find the answer to this!!

    Happy Days!!

    • This reply was modified 4 years, 6 months ago by Karen Turner.
    • This reply was modified 4 years, 6 months ago by Karen Turner.

    To upgrade to PHP7.4 try commenting out the function at the bottom of widget-contributors.php in the inc folder

    function form () {
    _e(‘No options available.’, AEC_NAME);
    }

    The calendar no longer works with WP5.5 as jquery has been updated and the plugin uses depreciated jquery that has been dropped. However, you can still use it by adding the WP plugin ‘Enable jQuery Migrate Helper’.

    You can also upgrade to PHP7.4 by commenting out the function at the bottom of widget-contributors.php in the inc folder

    function form () {
    _e(‘No options available.’, AEC_NAME);
    }*/

    These are just hacks to keep this great plugin working on your site for now!

    Thread Starter Karen Turner

    (@karen-turner)

    Could I possibly send a copy of the wp_participants_database_fields.sql with wp_participants_database_groups.sql with the 1000 fields so you can see what I mean and perhaps spot something very obvious that I am missing?

    Is that possible or not?

    Thread Starter Karen Turner

    (@karen-turner)

    I have opened the database structure and it is showing ID as INT(4)

    when I roll back to participants database version 1.8.4.9 I can edit the new fields beyond ID 1000 with ID INT(3) or ID INT(4)

    but if I update to the latest version, I can edit the field with ID=999 but not ID=1000 or 1001 etc.

    Thread Starter Karen Turner

    (@karen-turner)

    I see this line at the end of the wp_participants_database_fields
    table:
    ALTER TABLE wp_participants_database_fields
    MODIFY id int(4) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=1;
    COMMIT;

    so I have also changed this to INT(4) and now the re-imported table structure shows ID INT(4). but still, when I get to ID 1000, I cannot edit a newly created field.

    Do you have any other ideas please?

    Thread Starter Karen Turner

    (@karen-turner)

    It says it is a primary Key, Is that why it doesn’t change?

    Thread Starter Karen Turner

    (@karen-turner)

    Hi,

    No, I only changed the structure to INT(4) in the PHPmyadmin, but now I have tried editing the wp_participants_database_fields file where it says
    CREATE TABLE wp_participants_database_fields (
    id int(4) NOT NULL,
    changing the 3 to 4 and deleting wp_participants_database_fields table from PHPmyadmin and re-importing but the ID still says INT(3), even though I have changed it to INT(4) in the file!!! I dont know very much about PHPmyadmin, so I really don’t know why this would be. Can you shed any light on this please?

    Thread Starter Karen Turner

    (@karen-turner)

    I am not sure how to increase the data size of the id column for the wp_participants_database_fields table.

    I have been onto PHPmyadmin and clicked on the structure of the wp_participants_database_fields table. I can see that ‘ID’ is type INT(3), so I tried changing this to INT(4), but that didn’t fix the problem. I cant see a way to change the data size.

    I have tried to search for the answer but cant find anything relating to changing the size of the data field for INT, so I don’t think I am looking for the right thing.

    Please can you explain what I need to do. Thank you

Viewing 15 replies - 1 through 15 (of 56 total)