Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Preferred way to create a PNG #261

Answered by codemasher
dabrandstetter asked this question in Q&A
Discussion options

I am using version 5.0.2. and asking myself what is the best way to create a png qr code?

at the moment i use:

$options = new QROptions();
$options->outputType = QROutputInterface::CUSTOM;
$options->outputInterface = QRGdImagePNG::class;
(new QRCode($options))->render('data');

but outputType and outputInterface are deprecated.
am I doing something wrong?

You must be logged in to vote

Hey, the deprecation is related to #223, which will remove/ignore the line $options->outputType = QROutputInterface::CUSTOM; in version 6 entirely.
Right now and as long as you're using version ^5.0 you will be fine.

Replies: 1 comment

Comment options

Hey, the deprecation is related to #223, which will remove/ignore the line $options->outputType = QROutputInterface::CUSTOM; in version 6 entirely.
Right now and as long as you're using version ^5.0 you will be fine.

You must be logged in to vote
0 replies
Answer selected by dabrandstetter
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /