We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 349
    • 76 Posts
    The validator at validator.w3.org always throws an error for my labels:

    Line 485, Column 30: syntax of attribute value does not conform to declared value
    <label for="Firma" class="">Firma: </label>
    The value of an attribute contained something that is not allowed by the specified syntax for that type of attribute. For instance, the “selected” attribute must be either minimized as “selected” or spelled out in full as “selected="selected"”; the variant selected="" is not allowed.

    That´s because of the empty class attribute. The empty class is created by eform not by me.

    This fails:
    <li>
        <label for="[+firma+]">Firma: </label>
        <input name="Firma" id="[+firma+]" type="text" />
    </li>


    This works:
    <li>
        <label for="firma2">Firma2: </label>
        <input name="Firma2" id="firma2" type="text" />
    </li>
    

    It seems to be a error with placeholders.
    My placeholders are defined in assets/snippets/eform/lang/german.php like this:
    $_lang['firma'] = "Firma";

    and are beeing added to the $fields array via snippet "getFormFields"
    <?php
    function getFormFields(&$fields){
    global $_lang;
    foreach ($_lang as $k => $v) {
    $fields[$k] = $v;
    }
    return true;
    }
    ?>

    eform code:
    [[getFormFields]]
    
    [[kontakte]]
    
    [[eForm? &formid=`kontaktformular` &eFormOnBeforeMailSent=`kontakte` &to=`[email protected]` &replyto=`&replyto=`Email` &eFormOnBeforeFormMerge=`getFormFields` &noemail=1 &language=`german` &tpl=`eformtest` &report=`kontaktformularBericht` &invalidClass=`error` &requiredClass=`error` &protectSubmit=`false` &subject=`Kontakt` &jScript=`[(site_url)]assets/templates/standard/js/jquery-validate/jquery.validate.js,[(site_url)]assets/templates/standard/js/jquery-validate/localization/messages_[+language+].js,[(site_url)]assets/templates/standard/js/jquery-validate/cmxforms.js,[(site_url)]assets/templates/standard/js/jquery.metadata.js,[(site_url)]assets/templates/standard/js/kontaktformular.js`]]

    I fixed this by myself by commenting out the line 699 in eform.inc.php:
    $tpl = str_replace($fld,$newTag,$tpl);

    but this should be fixed generally, or am i wrong?