Skip to content

Instantly share code, notes, and snippets.

@ahsankhatri
Created February 18, 2015 09:54
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 ahsankhatri/856fadc989a6c6681fa4 to your computer and use it in GitHub Desktop.
Save ahsankhatri/856fadc989a6c6681fa4 to your computer and use it in GitHub Desktop.
Regular Expression for search CI & Native parameter in files. i.e: _GET _POST _REQUEST input->post() input->get() input->get_post() form_validation set_rules.
(this(?:\s+)?->(?:\s+)?(?:input|form_validation)(?:\s+)?->(?:\s+)?(?:get_post|get|post|set_rules)(?:\s+)?\((?:\s+)?(?:'|\")(?<param>[^'\"]+)(?:'|\")(?:.*?)?(?:\s+)?\)|_(?:REQUEST|GET|POST)(?:\s+)?\[(?:\s+)?(?:'|\")(?J)(?<param>.+?)(?:'|\")(?:\s+)?\])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment