johnners Posted June 14, 2022 Share Posted June 14, 2022 Hey all, I've got a form which has several visibility restrictions set - based on other form fields. For example, show "Gritting Machinery" if they click on Gritting Machinery in the "own Machinery" field. own_machinery=Gritting Machinery In preview it works fine, however on the live site (hidden page) it just displays every single field even though they are unselected etc... Am I missing something? I'm very very new to process wire (used to wordpress) so I'm learning rapidly but I cannot see anything wrong by googling etc. Link to comment Share on other sites More sharing options...
DV-JF Posted June 14, 2022 Share Posted June 14, 2022 Which method are you using to implement FormBuilder on your frontend? Link to comment Share on other sites More sharing options...
johnners Posted June 14, 2022 Author Share Posted June 14, 2022 so on the template page I've got this in the header $form = $forms->render('partner-form'); and then this further down the page <?php echo $form; ?> Is that what you mean? I'm attempting to add a new page to an existing site - so I've copied the contact page template and renamed it as partner, then created a new page and assigned the template as partner - then set up a new form called partner_form and added all the fields etc in the backend. Link to comment Share on other sites More sharing options...
johnners Posted June 14, 2022 Author Share Posted June 14, 2022 View the page here if that helps? Link to comment Share on other sites More sharing options...
DV-JF Posted June 14, 2022 Share Posted June 14, 2022 1 hour ago, johnners said: View the page here if that helps? Your link isn't working, but regardless, I suspect the following code is missing in the template file: <?php echo $form->styles; ?> <?php echo $form->scripts; ?> Have a look, here: I mostly use "Option B" to implement my forms when I don't need any fancy customization, so I don't have to worry about styles & scripts. Link to comment Share on other sites More sharing options...
johnners Posted June 14, 2022 Author Share Posted June 14, 2022 Agh! thank you, I checked in the header include and there was some php only showing the form scripts and styles on the contact page, so allowed it on this page too and its now displaying, although all of labels are being hidden, meaning the checkboxes and radio's have no text lol I love going through someone elses work. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now