Zoho Creator URL parameters fix

The Problem

If you are opening a Zoho Creator Form from a third party, and it includes the query string as “?first-name=Rob”, there is no direct way to get the value of “first-name” into a field in your Form. It will not work because Deluge names can’t have “-” in them.

Question posted at: https://forums.zoho.com/topic/

The Solution

There are only two places in Zoho Creator that can read URL parameters. 1. Form and 2. Pages. Both don’t accept “-” in parameter/field names. So, the optimal solution will be,

  1. Write a php file to convert “-” formatted query strings into “_” formatted query strings and open Zoho Creator Form with new query strings
  2. Host it on your server
  3. Link your hosted php file to your third party

The Php Code

I have given the php code below. You can change the Location url to your Zoho Creator Form Url

$query_string = $_SERVER['QUERY_STRING'];
parse_str($query_string, $query_array);
foreach ($query_array as $key => $value) {
$newkey = str_replace("-", "_", $key);
$query_array[$newkey] = $value;
unset($query_array[$key]);
}
header("Location:https://app.zohocreator.com/aorborctechnologies/url-params/#Form:Contact?" . http_build_query($query_array) );

Demo

Click https://aorborc.com/samples/php/demo/ and you will be redirected to our Zoho Creator Form with the formatted query strings.