Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
jsonp nginx support
location / {
# JSONP-support
if ( $arg_callback ) {
echo_before_body '$arg_callback(';
echo_after_body ');';

This comment has been minimized.

Copy link

tawanda commented Sep 15, 2015

I get the following error

unknown directive "echo_before_body" in /etc/nginx/sites-enabled/default:38



This comment has been minimized.

Copy link
Owner Author

hannseman commented Oct 6, 2015

Hey @tawanda, sorry for the late reply. You'll need the HTTP echo module installed. If you are running ubuntu you could install the package nginx-extras to get access to the echo module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.