Support » Plugin: WP Weixin » Missing QR image for authentication

  • Resolved lijitimit


    On a regular single install, I had no issues with this plugin. However we have recently moved to a multisite install and the image for the QR code (wechat authenticate) does not load and shows a 500 error.

    Currently, I’m testing on a local host, so I know it will not actually authenticate, however I was experiencing the same issue on the live site. We are also using Amazon s3 to serve regular images and cloudflare CDN (chinese version). Site hosted on amazon in china.

    Here is the error:

    Fatal error: Uncaught Error: Call to undefined method QRcode::png() in /app/public/wp-content/plugins/wp-weixin/inc/class-wp-weixin-settings.php:995 Stack trace: #0 /app/public/wp-content/plugins/wp-weixin/inc/class-wp-weixin-settings.php(339): WP_Weixin_Settings::output_get_qrcode('http://sandbox3...', 5, 2, 0) #1 /app/public/wp-content/plugins/wp-weixin/inc/class-wp-weixin-auth.php(119): WP_Weixin_Settings::get_qrcode('http://sandbox3...') #2 /app/public/wp-includes/class-wp-hook.php(284): WP_Weixin_Auth->parse_request() #3 /app/public/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array) #4 /app/public/wp-includes/plugin.php(531): WP_Hook->do_action(Array) #5 /app/public/wp-includes/class-wp.php(387): do_action_ref_array('parse_request', Array) #6 /app/public/wp-includes/class-wp.php(737): WP->parse_request('') #7 /app/public/wp-includes/functions.php(1105): WP->main('') #8 /app/public/wp-blog-header.php(16): wp() #9 /app/public/index.php(17): require('/app/public/wp-...') #10 {main} thrown in /app/public/wp-content/plugins/wp-weixin/inc/class-wp-weixin-settings.php on line 995

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Alexandre Froger


    Hello @lijitimit !
    Thank you for reaching out, and apologies for replying so late.
    First of all, because it has to communicate with Tencent’s servers, WP Weixin cannot be tested on localhost – it has to be tied to a domain name with an ICP as per China’s cybersecurity law.

    Regarding your specific QR code issue, I am not sure how to reproduce: QRcode::png() is a method found in /wp-content/plugins/wp-weixin/lib/phpqrcode/phpqrcode.php. It is included in /wp-content/plugins/wp-weixin/wp-weixin.php *only in case the class* QRcode *does not exist*. Could there be that another plugin is already registering this class name without using namespaces, therefor creating a conflict?

    Hi Alexandre. I’ve tried reaching out on Wechat. There’s a few things I wouldn’t mind talking to you about. I’ll send you another request. I’d love to connect! Wechat ID lijitimit aka James

    Sorry, also noticed the name on your contact QR is Dan Froal? Is that correct?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Missing QR image for authentication’ is closed to new replies.