Skip to content

Instantly share code, notes, and snippets.

@mritzmann
Created August 5, 2018 19:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mritzmann/4078020a37d5f5a6ae3b9a07dcf58bbd to your computer and use it in GitHub Desktop.
Save mritzmann/4078020a37d5f5a6ae3b9a07dcf58bbd to your computer and use it in GitHub Desktop.
mevdschee/php-crud-api: Issue #393: dot in id
diff --git a/api.php b/api.php
index ee0769c..080f432 100644
--- a/api.php
+++ b/api.php
@@ -1887,7 +1887,7 @@ class PHP_CRUD_API {
extract($settings);
$table = $this->parseRequestParameter($request, 'a-zA-Z0-9\-_');
- $key = $this->parseRequestParameter($request, 'a-zA-Z0-9\-_,'); // auto-increment or uuid
+ $key = $this->parseRequestParameter($request, 'a-zA-Z0-9\-,\.'); // auto-increment or uuid
$action = $this->mapMethodToAction($method,$key);
$include = $this->parseGetParameter($get, 'include', 'a-zA-Z0-9\-_,');
$page = $this->parseGetParameter($get, 'page', '0-9,');
@mritzmann
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment