Let the client choose the protocol for QR images (see #477)
This commit is contained in:
parent
96ed39c9e5
commit
55e0e32395
@ -6,10 +6,8 @@ class QRImageTheme extends Themelet {
|
|||||||
public function links_block($link) {
|
public function links_block($link) {
|
||||||
global $page;
|
global $page;
|
||||||
|
|
||||||
$protocol = is_https_enabled() ? "https://" : "http://";
|
|
||||||
|
|
||||||
$page->add_block( new Block(
|
$page->add_block( new Block(
|
||||||
"QR Code","<img alt='QR Code' src='{$protocol}chart.apis.google.com/chart?chs=150x150&cht=qr&chl={$link}' />","left",50));
|
"QR Code","<img alt='QR Code' src='//chart.apis.google.com/chart?chs=150x150&cht=qr&chl={$link}' />","left",50));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user