Skip to content

Instantly share code, notes, and snippets.

@michaeldelorenzo
Last active December 15, 2015 19:19
Show Gist options
  • Save michaeldelorenzo/5310083 to your computer and use it in GitHub Desktop.
Save michaeldelorenzo/5310083 to your computer and use it in GitHub Desktop.
:javascript
window._popup_closed = function(){
location.href = "#{@my_instance_var_uri_string}"; // replace the opening window document with this one
window._popup_closed = null; // remove on close callback
};
var connect_path = "/auth/#{@platform name}"; // the oauth destination - there is a route for these
var new window_specs = ""; // your window opening parameters
// open the new window
auth_window = window.open(connect_path,null,new_window_specs,false);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment