小编use*_*790的帖子

从Python Social Auth获取访问令牌

我在我的网站上实现了Python Social Auth,我正在尝试访问(在登录过程之后)用户获得的访问令牌.我可以在Django管理员身上看到有一个名为extra_data的字段,其中包含访问令牌,但我不知道如何从我的代码中访问它.

任何的想法?

我想在Django Social Auth中做类似的事情:http://django-social-auth.readthedocs.org/en/latest/tokens.html

python django python-social-auth

7
推荐指数
1
解决办法
4374
查看次数

PreventDefault不阻止表单发送

我有一个非常简单的页面,其中有一个表单,我试图阻止使用jQuery发送,但代码令人惊讶地无法正常工作.有任何想法吗?

<!DOCTYPE html>
<html>
   <head>
        <script src="http://code.jquery.com/jquery-2.1.1.min.js"></script>
        <script>

            $("#searchForm").submit(function(e){
               e.preventDefault();
         });

    </script>

</head>
<body>
    <form id="searchForm">
      <input name="q" placeholder="Go to a Website">
      <input type="submit" value="Search">
    </form>
    <pre id="response"></pre>
</body>
Run Code Online (Sandbox Code Playgroud)

html javascript jquery

5
推荐指数
1
解决办法
254
查看次数

标签 统计

django ×1

html ×1

javascript ×1

jquery ×1

python ×1

python-social-auth ×1