February 14, 2012 at 12:55 pm #703jaredMember
Hi please tell me how I can get a checkbox with some text containing a link to my TOS page? This field should be required and should show the red validation message if the user tries to submit without checking the box. I can’t figure out what needs to go into the field options for a checkbox where it will understand the hyperlink html.
In my latest attempt, I am escaping many special characters like the equals sign and the quotes but I can’t get anything to work. I’ve tried several variations but it just doesn’t seem to be liking the hyperlink in the field options for a checkbox.
February 14, 2012 at 1:39 pm #705KhaledMember
- This topic was modified 9 years, 9 months ago by jared.
You can use HTML field and checkbox field together to create your TOS page link and validation.
In HTML field, you can put your hyperlink and data. In checkbox, write ‘Aggreed TOS.’ or something like this in ‘Field Option’ and also check required from checkbox configuration.
Thanks.February 15, 2012 at 3:41 am #712jaredMember
Thanks. What I ended up doing was taking a look at the HTML generated for a normal required checkbox field without the hyperlink. I then used that as a guide to create an HTML field complete with the same div wrapper, css classes, label and an input checkbox field with the same checkbox validator class. Also, it was important that my label and input checkbox had an ID or it would not work correctly.
May I suggest that you document the HTML field in greater detail? For example, I had to fiddle with it a lot before I found out that I should not be using quotes anywhere in my HTML markup as your plugin seems to be inserting the quotes automatically.April 6, 2012 at 1:29 pm #1047andi_tMember
i’ve tried to put a hyperlink into the htmlfield, but always i got an unusual link: http://www.domain.tld/page/subpage/%5C%27http://www.domain.tld%5C%27
I’ve put the registry form on a subpage, and have used the following link in the htmlfield TEST.
What is my Problem?
BR AndiApril 7, 2012 at 12:27 am #1050KhaledMember
With version 1.1.2rc2, Please follow bellowed instructions:
1. Open user-meta/controllers/umFiledsController.php by any ftp client.
2. Replace (line 86)
update_option( $userMeta->options[‘fields’], $data );
update_option( $userMeta->options[‘fields’], stripslashes_deep($data) );
3. Save changes.
Thanks.April 7, 2012 at 2:27 am #1052andi_tMember
this was great.
Now i have put the text and the link in the checkbox resp. the Field Description of it. And it works fine 🙂
- You must be logged in to reply to this topic.