codemasher 5 years ago
parent
commit
6978a85294
1 changed files with 1 additions and 1 deletions
  1. 1 1
      examples/QRImageWithText.php

+ 1 - 1
examples/QRImageWithText.php

@@ -92,7 +92,7 @@ class QRImageWithText extends QRImage{
 
 
 		// loop through the string and draw the letters
 		// loop through the string and draw the letters
 		foreach(\str_split($text) as $i => $chr){
 		foreach(\str_split($text) as $i => $chr){
-			\imagechar($this->image, $textSize, $i * $w + $x, $this->length, $chr, $fontColor);
+			\imagechar($this->image, $textSize, (int)($i * $w + $x), $this->length, $chr, $fontColor);
 		}
 		}
 	}
 	}