Hello!
Are you getting this error when trying to export to csv or pdf?
I get it as soon as I hit the export option. After searching dates and form name. It never gives me an option for csv or pdf.
The 400 error was being caused by the server rejecting the curly braces in the json part of the url. RFC 1738 states that they are unsafe, so some hosts are blocking them. There is a fix, but it requires modifying 2 file sin the plugin.
Oh i see could you tell me which changes would be needed? If those doesn’t affect in anything else i can add them to the plugin.
Regards!
Encode the JSON part of the url in Entries_bundle.js at line 55829:
encodeURIComponent(JSON.stringify({
Form: this.SearchedForm,
StartDate: this.SearchedStartDate,
EndDate: this.SearchedEndDate,
Conditions: this.SearchedAdvancedSearchIsShown ? this.SearchedConditions : [],
Nonce: SmartFormsEntriesVar.Nonce
}));
Decode the url in smart-forms-ajax.php on line 588:
$data=RednaoJSONSanitizer::Sanitize(json_decode(stripslashes(urldecode($_GET['data']))),(object)[
"Nonce"=>'',
"Form"=>0,
"StartDate"=>0,
"EndDate"=>0,
"Conditions"=>[(object)[
"FieldId"=>"",
"Comparison"=>"",
"Value"=>"",
]]
]);
Is this change in the latest version?