Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #2 from jhitesma/master

Fixed QR code URL
  • Loading branch information...
commit f9e26734fde1030bb7305178d7fd1d3334f4540b 2 parents 502c7d2 + 45bc728
@chregu authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  lib/GoogleAuthenticator.php
View
2  lib/GoogleAuthenticator.php
@@ -66,7 +66,7 @@ protected function hashToInt($bytes, $start) {
public function getUrl($user, $hostname, $secret) {
$url = sprintf("otpauth://totp/%s@%s?secret=%s", $user, $hostname, $secret);
$encoder = "https://www.google.com/chart?chs=200x200&chld=M|0&cht=qr&chl=";
- $encoderURL = sprintf( "%sotpauth://totp/%s@%s%%3Fsecret%%3D%s",$encoder, $user, $hostname, $secret);
+ $encoderURL = sprintf( "%sotpauth://totp/%s@%s&secret=%s",$encoder, $user, $hostname, $secret);
return $encoderURL;

1 comment on commit f9e2673

@stephangroen

Odd, I had to change this back for it to generate a proper QR code.

Please sign in to comment.
Something went wrong with that request. Please try again.