2

As per the comments, the issue turned out to be that jQuery wasn't included on the page, so $ wasn't defined. In general, make sure to check the devtools console for error messages and use the debugger to find out why specific pieces of code aren't working as intended.


2

If you want multiple user accounts in Craft, then you'd need Craft Pro, regardless of the type of site you're trying to building on the front-end.


2

Would removing required via JS be an option?


2

The second parameter of the input function is the name attribute, which you currently have as contactName. Assigning it in the options like you have does not override the initial supplied parameter. Try this: {{ input('text', 'fields[contactName]', entry.contactName, { id: 'contactName' }) }}


2

If you're not using Craft's user groups for permissions, the solution you suggest is more or less exactly what sprung to my mind. You could create a Category Group called Permissions (just to keep it distinct from Craft's internal user groups), add the initial permission categories that are needed, then create a new field named Permissions that can be added ...


2

There are ways to check the email as soon as it's entered, but it's a bit more involved. The built-in controller action to create new users already does this check for you, so you should see if you can't utilize this to achieve good UX. when I try to create a new user with the (same) email, the form obviously won't submit successfully and reload the page ...


1

I just came across this post & discussion which is exactly what I needed: How to immediately redirect to an entry after creating the new entry from a frontend form? Worked like a charm: {{ redirectInput('{uri}') }} Thanks to https://craftcms.stackexchange.com/users/4169/august-miller for the answer.


1

Many of those advanced endpoints are undocumented, but you can find out a lot with the devtools. If you use the Delete (with Descendants) option in the backend and check the devtools, you can see it uses craft\controllers\ElementIndexesController::actionPerformAction. This method expects an elementAction parameter to tell it which action to perform. You can ...


1

You can find a specific folder using the Assets service: https://docs.craftcms.com/api/v3/craft-services-assets.html#public-methods If you know all the necessary information when that template is parsed, the findFolder method might be useful but ensureFolderByFullPathAndVolume is probably more precise. For example: {{ hiddenInput( 'secret_folder_id', ...


1

Found a solution. I just add or remove the html5 required tag on load via Javascript. This way the js who duplicates the form can do whatever it wants and the html remains untouched: // adds required tag to inputs on page load $("#shippingAddress-firstName").attr("required", ""); $("#shippingAddress-lastName").attr(...


Only top voted, non community-wiki answers of a minimum length are eligible