Problem/Motivation

The WhatsApp button is one of our preferred buttons but clicking on it loads about:blank on the frame.

Steps to reproduce

Just hit the button and see it load an about:blank

Proposed resolution

I made a patch for a fix.

Issue fork rrssb-3315552

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

chike created an issue. See original summary.

adamps’s picture

Status: Active » Needs review
tanuja bohra’s picture

StatusFileSize
new30.78 KB
new61.32 KB

Verified and tested the patch on 9.5.x. Now WhatsApp is not showing blank but on the popup, it is showing this ->

This link is incorrect. Close this window and try a different link.
Refer to the after_patch screenshot.

raveen_thakur51’s picture

@AdamPS,
I have reviewed & Implemented the Patch on my Drupal website having version 9.5, PHP version - 8.1
The patch has been implemented successfully. Can be moved to RTBC!
Please & Thank You.

raveen_thakur51’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new29.05 KB
new81.61 KB

I am attaching the screenshots for reference. Please have a look (before-patch.png, after-patch.png). Moving to RTBC!
And Thank You.

adamps’s picture

Status: Reviewed & tested by the community » Needs work

Thanks.

  1. It seems that the current API is https://wa.me/?text=urlencodedtext. The patch seems to be using the old API format. Please see this link https://stackoverflow.com/questions/29218378/mobile-website-whatsapp-but... and other pages on the Internet.
  2. The text should be URL-encoded, so use %20 instead of space.
raveen_thakur51’s picture

.

bharath-kondeti made their first commit to this issue’s fork.

bharath-kondeti’s picture

StatusFileSize
new455 bytes

Here is the patch. Please review

bharath-kondeti’s picture

Status: Needs work » Needs review
adamps’s picture

Status: Needs review » Needs work

Thanks. It should not include the word 'send'

raveen_thakur51’s picture

StatusFileSize
new89.92 KB

Adding test screenshot as per #10, #12. Thank You.

adamps’s picture

Status: Needs work » Needs review
StatusFileSize
new451 bytes

  • AdamPS committed 6f451b9b on 8.x-2.x
    Issue #3315552 by bharath-kondeti, AdamPS, chike: WhatsApp button not...
adamps’s picture

Status: Needs review » Fixed

Please can someone test?

raveen_thakur51’s picture

#14 seems to be working fine. Thank You. @Adam, Is there no credit for reviewers?

adamps’s picture

Great thanks. Sure you deserve credit, now fixed - unfortunately the system doesn't seem to assign credit for reviewers automatically.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.