Snippets Collections
# Download the helper library from
import os
from import Client

# Find your Account SID and Auth Token at
# and set the environment variables. See
account_sid = os.environ['TWILIO_ACCOUNT_SID']
auth_token = os.environ['TWILIO_AUTH_TOKEN']
client = Client(account_sid, auth_token)

message = client.messages.create(

* WhatsApp button in product archive
add_action('woocommerce_after_shop_loop_item', 'add_a_custom_button', 5 );
function add_a_custom_button() {
    global $product;

    // Not for variable and grouped products that doesn't have an "add to cart" button
    if( $product->is_type('variable') || $product->is_type('grouped') ) return;

    // Output the custom button linked to the product
    echo '<div style="margin-bottom:10px;">
        <a class="button custom-button" target="blank" href="' . esc_attr( $product->get_title() ) . '">' . _('שלח ווטסאפ') . '</a>

Tue May 25 2021 07:44:06 GMT+0000 (UTC)

#python #whatsapp

Save snippets that work with our extensions

Available in the Chrome Web Store Get Firefox Add-on Get VS Code extension