代码之家  ›  专栏  ›  技术社区  ›  zotherstupidguy

如何在GSP中使用openid4java实现openID

  •  0
  • zotherstupidguy  · 技术社区  · 17 年前

    如何在gsp中构建openID返回URL??

    Define a ReturnURL
    
    This is the endpoint where your webapp will receive and process the authentication responses from the OpenID Provider.
    
        String _returnURL = "http://example.com/openid";
    

    参考: http://code.google.com/p/openid4java/wiki/QuickStart

    1 回复  |  直到 17 年前
        1
  •  1
  •   Rhysyngsun    16 年前

    假设你有圣杯。在配置中正确设置服务器URL。groovy文件您可以在绝对值设置为true时使用createLink标记:

    grails.serverURL = "http://example.com"
    
    String _returnURL = createLink(controller:'openid', action:'handleReturn', absolute:true)
    
    // _returnURL -> http://example.com/appname/openid/handleReturn