EasyWayB Discussion

A Easy Way to Start Your Business Online

Woocommerce Confirm Booking Email to Show Customer and Additional Information


For Woocommerce Confirm Booking Email to Show Customer Information you need filter “woocommerce_bookings_gcalendar_sync”.
If you filter “woocommerce_bookings_gcalendar_sync” then update content of Google event when a booking is created or updated.
Woocommerce Booking use $event = apply_filters( 'woocommerce_bookings_gcalendar_sync', $event, $booking ); on includes/class-wc-bookings-google-calendar-connection.php file. You need to filter “woocommerce_bookings_gcalendar_sync”.

Enquiry For Your Project

Sample Code

add_filter( 'woocommerce_bookings_gcalendar_sync', 'easywayb_filter_bookings_gcalendar_sync', 10, 2 );
function easywayb_filter_bookings_gcalendar_sync( $event, $booking ){
$booking_id = $booking->id; // Woocommerce Booking ID
$order_id = $booking->order_id; // Woocommerce Order ID
$order = new WC_Order($order_id);

$description = '';
$description .= 'Customer name : '.$order->billing_first_name.' '.$order->billing_last_name;
$description .= 'Customer phone no : '.$order->billing_phone;
$description .= 'Customer shipping address : '.$order->shipping_address_1.', '.$order->shipping_address_2.', '.$order->shipping_city.', '.$order->shipping_state.', '.$order->shipping_postcode.', '.$order->shipping_country;
$description .= 'Customer provided note: : '.$order->get_customer_note();

$event['description'] .= $description;
return $event;

Or Visit https://stackoverflow.com/questions/71696716/woocommerce-confirm-booking-email-to-show-customer-and-additional-information.

Enquiry For Your Project

EasyWayB Testimonials Slider Plugin

We build testimonial plugin for our client for easy use.
  • Testimonial image
  • Testimonial title or Tagline
  • Testimonial content or Review message
  • Fully Responsive and Mobile friendly.
  • Easy To Use – No Coding Required.
  • Shortcode Generator for each category.

Enquiry For Your Project


[ewb-testimonial count="10" order="ASC" orderby="date"]

Download this plugin now Click.


Create Google Shared Drive with Google API in php

To run this quickstart, you need the following prerequisites
  • PHP 5.4 or greater with the command-line interface (CLI) and JSON extension installed
  • The Composer dependency management tool
  • A Google Cloud Platform project with the API enabled. To create a project and enable an API, refer to Create a project and enable the API
  • A Google account with Google Drive enabled.

Enquiry For Your Project

  • Install the Google Client Library :
    composer require google/apiclient:^2.0
  • Set up API : Create a file named quickstart.php in your working directory and copy in the following code:

    require __DIR__ . '/vendor/autoload.php';

    if (php_sapi_name() != 'cli') {
    throw new Exception('This application must be run on the command line.');

    * Returns an authorized API client.
    * @return Google_Client the authorized client object
    function getClient()
    $client = new Google_Client();
    $client->setApplicationName('Google Drive API PHP Quickstart');
    $client->setPrompt('select_account consent');

    // Load previously authorized token from a file, if it exists.
    // The file token.json stores the user's access and refresh tokens, and is
    // created automatically when the authorization flow completes for the first
    // time.
    $tokenPath = 'token.json';
    if (file_exists($tokenPath)) {
    $accessToken = json_decode(file_get_contents($tokenPath), true);

    // If there is no previous token or it's expired.
    if ($client->isAccessTokenExpired()) {
    // Refresh the token if possible, else fetch a new one.
    if ($client->getRefreshToken()) {
    } else {
    // Request authorization from the user.
    $authUrl = $client->createAuthUrl();
    printf("Open the following link in your browser:\n%s\n", $authUrl);
    print 'Enter verification code: ';
    $authCode = trim(fgets(STDIN));

    // Exchange authorization code for an access token.
    $accessToken = $client->fetchAccessTokenWithAuthCode($authCode);

    // Check to see if there was an error.
    if (array_key_exists('error', $accessToken)) {
    throw new Exception(join(', ', $accessToken));
    // Save the token to a file.
    if (!file_exists(dirname($tokenPath))) {
    mkdir(dirname($tokenPath), 0700, true);
    file_put_contents($tokenPath, json_encode($client->getAccessToken()));
    return $client;

    // Get the API client and construct the service object.
    $client = getClient();
    $service = new Google_Service_Drive($client);

  • Run the API
    Run the sample using the following command:

    php quickstart.php
    The first time you run the sample, it prompts you to authorize access:

    1. Browse to the provided URL in your web browser.
      If you are not already signed in to your Google account, you are be prompted to sign in. If you are signed in to multiple Google accounts, you are asked to select one account to use for the authorization.
    2. Click the Accept button.
    3. Copy the code you’re given, paste it into the command-line prompt, and press Enter.
  • Create Google Shared Drives:

    $folder_name = 'EasyWayB Drive';
    $metadata = new Google_Service_Drive_TeamDrive();
    $resp = $service->teamdrives->create(uniqid(), $metadata);
    $teamdrive_id = $resp->id;

  • Permissions Access Google Shared Drives:

    $email = 'easywayb.customer.service@gmail.com';
    $metadata = new Google_Service_Drive_Permission();
    $optParams = [
    'supportsTeamDrives' => true
    $permision = $service->permissions->create($teamdrive_id, $metadata, $optParams);
    $permision_id = $permision->id;

Or visit https://stackoverflow.com/questions/71698428/create-google-shared-drive-with-google-api-in-php.

The journey of Website Creation

How Website is Created by EasyWayB
  • If you are thinking of creating a Website your thoughts must be racing around 3 main issues – How the website is created, how much it takes time and how much money is required.
  • Let’s discuss the details. Website creation mainly involves the following
    1. Discuss
    2. Discover
    3. Design
    4. Content Writing
    5. Development
    6. Deliver

Enquiry For Your Project

  • Discuss: Discussion mainly involves meeting and communicating with the client about the website details. Discussing and discovering the Purpose, Main Goals, and Target Audience of the business.
  • Discover: After the discussion, the research team with the designers, set themselves to discover trendy designs, features, functionalities of the Website design depending on the industry and goals of the business. Most often the agency sends demo designs to the client, as examples.
  • Design: During the design phase, the website takes shape. All the visual content, such as images, photos, and videos is created at this step. Layouts contain colors, logos, images. Once the design is completed it is forwarded to the client as a general understanding of the future product.
  • Content Writing: The very essence of communication is portrayed through words when it comes to a Website. Therefore, once the design is finalized, the content writer fills the demo texts with catchy headlines, call to actions, product or service descriptions and much more.
  • Development: Web Development means making the Website functional. Frameworks and CMS should be implemented to make sure that the server can handle the installation and the functionalities work smoothly. Testing is the most routine part of the process.
  • Deliver: After the coding and testing process is completed the developers and tester work for hand in hand to check and re-check a website. Once all the bugs are removed and the website has met the cross-browser compatibility the website is uploaded to a server known as FTP (File Transfer Protocol) software. Once all the files are deployed and the website works fine, it’s delivered to the client.
  • easywayb.com is one of the top web design and development companies in India. Contact us for a free quote on Website designing and development.

Enquiry For Your Project