Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/238.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 谷歌一键注册和自动登录不会返回idToken_Php_Jquery - Fatal编程技术网

Php 谷歌一键注册和自动登录不会返回idToken

Php 谷歌一键注册和自动登录不会返回idToken,php,jquery,Php,Jquery,我正在实施谷歌一键注册和自动登录,我遵循中给出的说明 我得到了所有的细节,比如 authDomain、authMethod、,​ 显示名称,​ id和profilePicture 但无法获取idToken 有人能帮我拿这个吗 这是我的密码: const retrievePromise = googleyolo.hint({ supportedAuthMethods: [ 'googleyolo://id-and-password', 'https://accounts.

我正在实施谷歌一键注册和自动登录,我遵循中给出的说明

我得到了所有的细节,比如

authDomain、authMethod、,​ 显示名称,​ id和profilePicture

但无法获取
idToken

有人能帮我拿这个吗

这是我的密码:

const retrievePromise = googleyolo.hint({
    supportedAuthMethods: [
    'googleyolo://id-and-password',
    'https://accounts.google.com'
    ],
    supportedIdTokenProviders: [{
    uri: 'https://accounts.google.com',
    clientId: GOOGLE_CLIENT_ID
    }]
});
retrievePromise.then((credential) => {  
    //here i am not getting credential.idToken                
});

您需要显示您迄今为止尝试过的代码。感谢Hetal的快速响应。下面是我正在尝试的代码-
constretrievepromise=googleyolo.hint({supportedAuthMethods:['googleyolo://id-and-password',                     'https://accounts.google.com'],SupportedTokenProviders:[{uri:'https://accounts.google.com“,clientId:GOOGLE_CLIENT_ID}]});retrievePromise.then((credential)=>{//not getting credential.idToekn});
可能的重复:可能的重复