Like you may have noticed, GravityForms 2.4+ includes (beta / hidden) repeater feature. But the class name used in GF is the same GF_Field_Repeater and break this add-on.
This will cause a “PHP Fatal error: Cannot declare class GF_Field_Repeater, because the name is already in use” error.
I ended up replacing the class name GF_Field_Repeater with GF_Field_Repeater2 in all occurrences in all files of the plugin.
And renaming every occurence of “repeater” with “repeater2” and ‘repeater’ with ‘repeater2’ (note the difference between ‘ and “).
Finally renamed files containing repeater with repeater2 (i.e. class-gf-field-repeater.php becomes class-gf-field-repeater2.php, etc ) and renamed the plugin folder.
Obviously, this is a in quick and dirty mode, still I edited the plugin;
but A/it is no longer supported (Big up and many thanks anyway to the author) so no upgrade available = no upgrade overwrites
B/I guess GF will provide soon a gui for its native repeater.
I repacked the whole working version, so you can download it here
https://www.dropbox.com/s/50kahlyb67gkq18/repeater2-add-on-for-gravity-forms.zip?dl=0
This works at least for me. I’ve just tested it very briefly on a basic form, so I dont guarantee blah blah it will work for you Disclaimer blah blah.
]]>If you are no longer maintaining this plugin I am interested in taking over and continuing development. Let me know what you think.
]]>Gravity Forms 2.4 has implemented a Repeater field in beta. The Repeater field is only available programmatically at the moment. However, the plugins share a common class name and if you upgrade you will have a Fatal Error that causes your site to not load.
PHP Fatal error: Cannot declare class GF_Field_Repeater, because the name is already in use in C:\xampp\htdocs\wp-content\plugins\repeater-add-on-for-gravity-forms\class-gf-field-repeater.php on line 635
]]>I got the paid for gravity forms and using this this repeater plugin and right away i get this error:
Warning: Illegal string offset ‘formId’ in /home/mraservi/public_html/wp-content/plugins/repeater-add-on-for-gravity-forms/class-gf-field-repeater.php on line 288
its the same error as this guy gets…
https://stackoverflow.com/questions/44235231/illegal-string-offset-formid-in-repeater-gravityform
I solved it with his solution by adding:
$value = array(); on line 287
Just wondering why this isnt added in the plugin already.
]]>Hello,
I have used Gravity Forms Repeater Addon. I want a group of fields to be repeatative in one of the forms in a website. The repeater addon that I have used provides the fields repeater functionality, as required. But it does not save the repeater fields value. On form submit, it shows empty value in email as well as in backend record for the fields in repeater section. Can anyone help me? Why this might be happening?
]]>Hi,
I’m using repeater for a single line text. The repeater appears correct on the form, but when I click on ‘+’ button to add more text box then it shows TypeError: gfRepeater_repeaters[e] is undefined
error in the console. I tried debugging for the issue but no luck.
I’m using WordPress 4.9.5, Gravity Forms 2.2.6 and Gravity Forms Repeater Add-On 1.0.9
Can you please check the issue?
]]>Hi everyone! Just wanted to let everyone know that I’m officially decommissioning this plugin as I am unable to maintain it anymore and Gravity Wiz has built a much better alternative. Good luck out there! ??
]]>First LOVE the plugin, use it often. For the first time I’ve needed to setup a repeater email field and want to have notifications sent to all of those emails entered. Everything works completely fine for the form, data, and admin notification “all fields”, and I can even see the repeater field as a choice in setting up an email “to” a field in the form, but then it doesn’t work. No error or bounces, just nothing.
I’d like it to send the same email to every email address (single repeated field) but separately. Is there any way this is supported? Or could you point me in the right direction of hook programming to add it? Parse through the array to send the email multiple times?
Thank you!
]]>Being that this plugin is no longer supported, I figured I’d post my solution for a Javascript error that this plugin was throwing. My error was:
Uncaught TypeError: Cannot read property ’64’ of undefined in gf-repeater.min.js.
I fixed this error by changing lines 286-288 in class-gf-field-repeater.php to:
if (empty($value)) {
$value = array();
$value['formId'] = $form_id;
The addition of $value = array();
is the fix.
Hope this helps someone!
]]>When using a checkbox field inside of a repeater and making the field required, it is requiring all the fields to be checked in order to validate.
Can this be fixed?
Hi,
Is there any way to display dynamic labels when repeater fields are added?
For example I want Name to display as Name1, Name2, … so on in repeater fields.
Thanks
]]>latest updates….
Cant remove repeater field and save form:
Uncaught TypeError: Cannot set property ‘repeaterRequiredChildren’
gf-repeater-admin.min.js:1 Uncaught TypeError: Cannot set property ‘repeaterRequiredChildren’ of null
at Object.<anonymous> (gf-repeater-admin.min.js:1)
at Function.each (load-scripts.php?c=1&load[]=jquery-core,jquery-migrate,utils,heartbeat,jquery-ui-core,jquery-ui-widget,jquery-ui-position,jquery-ui-menu,wp-a11y,jquery-ui-a&load[]=utocomplete,jquery-ui-tooltip&ver=4.8.2:2)
at gfRepeater_editforms_update (gf-repeater-admin.min.js:1)
at HTMLInputElement.onclick (admin.php?page=gf_edit_forms&id=11:1)
This plugin is not working with either the latest version of WP or within my theme requirements, are there any other plugins capable of repeating a GF form section(s) / group of fields with conditional logic capabilities?
Thank you!!!
]]>Hi,
Nothing happens when I click on the + and – buttons. Any idea how to solve this?
Also, it seems that since the creator of the plugin left, topics on this plugin support forum don’t get answers. Are there some alternatives to this plugin?
Thanks in advance,
A. Mayer
]]>Hi,
I have a large amount of inputs tucked within the repeater field. I would like to style even blocks differently than odd blocks. Im pretty decent at CSS, but I can’t think of a very good way to do this.
Actually I JUST came up with this (there’s 7 input in the repeater):
[data-repeater-childid="1"]:nth-of-type(even),
[data-repeater-childid="2"]:nth-of-type(even),
[data-repeater-childid="3"]:nth-of-type(even),
[data-repeater-childid="4"]:nth-of-type(even),
[data-repeater-childid="5"]:nth-of-type(even),
[data-repeater-childid="6"]:nth-of-type(even),
[data-repeater-childid="7"]:nth-of-type(even) {
background: red;
}
Any ideas on a better solution?
]]>Hi there,
I am using Gravity Forms Repeater add-on for adding multiple fields dynamically.When I am using conditional logic to show/hide the fields based on other field values, the field values are not showing up on the notification emails. But when I am not using conditional logic on the fields, the field values are showing in the notification email.
I’ve attached a screenshot below which shows that under Attendee 1, there is now data shown, whereas, under Attendee 2, there are some data.
I’ve entered the data in Attendee 1 fields and for some reason, it is not showing up on the notification emails
Link to screenshot showing the problem
Can anyone please help.
Thanks,
David.
Hi there
I get this warning messages:
Warning: Illegal string offset ‘formId’ in C:\xampp\htdocs\wp-content\plugins\repeater-add-on-for-gravity-forms\class-gf-field-repeater.php on line 287
Warning: Illegal string offset ‘children’ in C:\xampp\htdocs\wp-content\plugins\repeater-add-on-for-gravity-forms\class-gf-field-repeater.php on line 291
This is because the code it is trying to use a string like an array so my solution was add this line in 287:
$value = array();
this is the piece of code you must change:
if (empty($value)) {
$value = array();
$value['formId'] = $form_id;
if (!empty($repeater_start)) { $value['start'] = $repeater_start; }
if (!empty($repeater_min)) { $value['min'] = $repeater_min; }
if (!empty($repeater_max)) { $value['max'] = $repeater_max; }
if (!empty($repeater_children)) { $value['children'] = $repeater_children; }
$value = json_encode($value);
}
Hope this help
]]>I have an issue with the gravity forms repeator add-on on the website. When the values are entered on the repeator fields and submitted on the website. The repeator field data is not stored in database or is sent in emails. The data is missing.
I see that this happens only if I add a paging option to the form. My form is very big, so I have added it as a multi page form.
Any ideas on fixing it?
]]>In my case gravity Repeater add-on working only in preview in the form but if i tested in Fronted with using Shortcode ([gravityform id=”7″ title=”true” description=”true”]).
Then it’s not working. Can anyone please help me to sort this out…
Thank You
]]>I have an error with this plugin
Warning: Illegal string offset ‘formId’ in C:\xampp\htdocs\wp-content\plugins\repeater-add-on-for-gravity-forms\class-gf-field-repeater.php on line 287
Warning: Illegal string offset ‘children’ in C:\xampp\htdocs\wp-content\plugins\repeater-add-on-for-gravity-forms\class-gf-field-repeater.php on line 291
if (empty($value)) {
$value[‘formId’] = $form_id;
if (!empty($repeater_start)) { $value[‘start’] = $repeater_start; }
if (!empty($repeater_min)) { $value[‘min’] = $repeater_min; }
if (!empty($repeater_max)) { $value[‘max’] = $repeater_max; }
if (!empty($repeater_children)) { $value[‘children’] = $repeater_children; }
$value = json_encode($value);
}
Hi
How I can translate the button I have (or text) for the add / remove in the repeater? I am using WPML.
Also a question, if I like to have a unique number, for example on this page:
https://wp.member-diving.com/en/book-now-and-enquiry/
I have “Participant” and like to have there a number like #1 for participant 1, #2 for participant 2 etc, is this possible?
Regards,
Simon
]]>Hi and thanks for a great plugin.
The only issue I am having with it is that conditionals do not work. I have a form with a single checkbox. If that box is checked, I would like to show the repeater field.
The repeater itself does not have the option for conditional logic, but I also tried adding the conditional logic to the fields inside the repeater and it did not work. The whole G-form ends up getting display: none;
I hope this is something that can be fixed.
]]>I’m looking to use Gravity Forms “After Submission” hook to send the inputted data to a third party server.
Is there a way target the Entry Object Field Values?
add_action( 'gform_after_submission', 'post_to_third_party', 10, 2 );
function post_to_third_party( $entry, $form ) {
$post_url = 'https://thirdparty.com';
$body = array(
'first_name' => rgar( $entry, '1.3' ),
'last_name' => rgar( $entry, '1.6' ),
'message' => rgar( $entry, '3' ),
);
GFCommon::log_debug( 'gform_after_submission: body => ' . print_r( $body, true ) );
$request = new WP_Http();
$response = $request->post( $post_url, array( 'body' => $body ) );
GFCommon::log_debug( 'gform_after_submission: response => ' . print_r( $response, true ) );
}
]]>
Hi there
Hoping you can help me with an error I’m getting using Repeater Start and End in my form.
I’m trying to have a Product Field repeat, and I’m getting the following two errors back when I try to preview the form:
Warning: Illegal string offset ‘formId’ in /home/leadpal7/public_html/boilerpal.co.uk/wp-content/plugins/repeater-add-on-for-gravity-forms/class-gf-field-repeater.php on line 287
Warning: Illegal string offset ‘children’ in /home/leadpal7/public_html/boilerpal.co.uk/wp-content/plugins/repeater-add-on-for-gravity-forms/class-gf-field-repeater.php on line 291
I’ve tried switching out the Product field for a Single Text field, and I get the same response.
Can you shed any light on what the cause might be?
Thanks in advance!
]]>Getting the following error on multipage Gravity form.
<b>Notice</b>: Undefined index: conditionalLogic in <b>plugins/repeater-add-on-for-gravity-forms/class-gf-field-repeater.php</b> on line <b>156</b><br />
]]>Hi, I have a problem. total field does not work with product field calculation when user repeat item . could you help to solve this issue.
]]>Hello,
In my website i am using gravity form , and i have added Gravity Forms Repeater Add-On field in which i have selected dropdown field . But, after submission everytime it is getting first value of the dropdown in result.
For example: Suppose there are three dropdown in repeater field one is being selected with “option1”, second one is selected with “option 2” and third is being selected with “option 3”, but everytine result is showing option 1.
Please check and this help regarding this issue.
Thanks
]]>The repeater add-on works great, however, it won’t calculate the repeating number fields. I need it to add up and total the repeating fields. Is there any way to do that? Thanks.
]]>Hello,
I was wondering if it was possible and if not what would be involved with having a nested repeater fields.
Ideally, I’d like somethign like the below as an outcome:
<repeater>
Text Input (Activity)
<repeater>
Text Input (Day)
Text Input (Time)
</repeater>
</repeater>
That way within an activity there could be a variable amount of day/times.
Thanks for taking the time to having a look and responding.
Cheers,
]]>Hi,
Fields under the repeater are not saved. If you go back to previous step in the form you can see that the filled data is empty. Also the data is not sent upon submission.
Can you please check this issue?
]]>