<?php

$curl = curl_init();

// Get the current post ID.
$post_id = get_the_ID();

// Get the 'video_refresh_url' ACF field value for the current post.
$video_refresh_url = get_field("chau_video_refresh_url", $post_id);

// Use the variable $video_refresh_url for the cURL request.
curl_setopt_array($curl, [
  CURLOPT_URL => $video_refresh_url,
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer E9YdEy6ZAjvigAwY8jCxCJdE2zTp0AO8lv5Jk8sP",
    "User-Agent: insomnia/8.4.5"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  
  //process response to shorten url
  
  $responseData = json_decode($response, true);

// Extract the long URL
$longUrl = $responseData['value'][0]['file'];
  
  echo $longUrl;
  
  $yourls_api_url = 'https://links.omnichannelplus.com/yourls-api.php';
  
  $token = '63a72d7acd';
  
  // Prepare data for API request
$data = array(
    'signature' => $token,
    'action' => 'shorturl',
    'url' => $longUrl,
    'format' => 'json'
);
  
  // Initialize cURL
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $yourls_api_url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);

// Execute the request
$response = curl_exec($ch);
curl_close($ch);

// Decode the response
$shortUrlResponse = json_decode($response, true);

if (isset($shortUrlResponse['shorturl'])) {
    // Short URL
    echo 'Short URL: ' . $shortUrlResponse['shorturl'];
} else {
    // Handle error
    echo 'Error: ' . $shortUrlResponse['message'];
}
  
} ?>

Jacuzzi Bath Remodel

Hi, San! You requested an appointment

Appointment Date & Time
Preferred Contact Method[email protected] | +1000001432
Your Address

Your notes about the project

ComplaintDo I need a bathroom remodel? If so, please send me recommendations.

Our recommendation

Recommendation

Given the excellent condition of your bathroom, specifically your shower area and vanity, there’s no urgent need for any renovation or replacement. However, if you’re interested in enhancing your bathroom’s comfort and luxury, I would recommend considering our Jacuzzi bathtubs and thermaspas.

Our Jacuzzi bathtubs are known for their therapeutic benefits and modern designs that could seamlessly blend in with your existing decor. Upgrading to our bathtubs can transform your bathing experience into a private, spa-like retreat right in your home.

Our Jacuzzi thermaspas, on the other hand, provide a whole new level of relaxation with their high-performing hydrotherapy features. They can definitely boost the wellness potential of your bathroom.

We understand that financial planning is essential, so if these upgrades seem intriguing but you’re concerned about the cost, we have various financing options available to meet different budget requirements.

After...

Would you prefer to call us now?

At Jacuzzi Bath Remodel, we know that comfort should never come at the expense of style. That’s why, in addition to these innovative features, we also offer an array of aesthetic elements for you to choose from to update the appearance of your bathroom. Whether you opt for a Jacuzzi® bathtub/shower combo or choose to replace your existing tub with a new Jacuzzi® walk-in shower, you’ll be able to enjoy sophisticated and imaginative designs crafted from the best materials for increased beauty and durability.