Title: HTTPS? Is it possible to get yelpcdn.com resources via https?
Last modified: August 22, 2016

---

# HTTPS? Is it possible to get yelpcdn.com resources via https?

 *  Resolved [nlitend1](https://wordpress.org/support/users/nlitend1/)
 * (@nlitend1)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/)
 * I am moving my site to HTTPS and have migrated all of my links/resources to HTTPS
   except the two yelp resources that this plugin uses.
 * Is it possible to obtain those via HTTPS? If so, please assist me in doing so.
   I really like the plugin, but need the HTTPS for my site.
 * Thank you,
    nlitend1
 * [https://wordpress.org/plugins/yelp-widget-pro/](https://wordpress.org/plugins/yelp-widget-pro/)

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346183)
 * I just fixed this in the Pro version and am planning on releasing an update soon
   for HTTPS for the free version. If you can wait a few days it will be fixed.
 *  Thread Starter [nlitend1](https://wordpress.org/support/users/nlitend1/)
 * (@nlitend1)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346195)
 * Awesome! Thanks, SO much for the reply. What great support!. If you need a tester…
   just let me know… 😉 I look forward to that updated, as once I have that I can
   move my site to FULL HTTPS!
 * Thanks again,
    nlitend1
 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346196)
 * Are you pretty code savvy? I can provide a quick snippet to get you up and running
   quickly if you know how to update a plugin.
 *  Thread Starter [nlitend1](https://wordpress.org/support/users/nlitend1/)
 * (@nlitend1)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346201)
 * Yes. I was already trying to edit the php files when i put in the request. Please
   send me the snippet. I’d like to give it a go.
 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346202)
 * Ok, open up widget.php and replace “yelp_widget_curl” with:
 *     ```
       /**
        * @DESC: CURLs the Yelp API with our url parameters and returns JSON response
        */
       function yelp_widget_curl( $signed_url ) {
   
       	// Send Yelp API Call using WP's HTTP API
       	$data = wp_remote_get( $signed_url );
   
       	//Use curl only if necessary
       	if ( empty( $data['body'] ) ) {
   
       		$ch = curl_init( $signed_url );
       		curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true );
       		curl_setopt( $ch, CURLOPT_HEADER, 0 );
       		$data = curl_exec( $ch ); // Yelp response
       		curl_close( $ch );
       		$data = yelp_update_http_for_ssl( $data );
       		$response = json_decode( $data );
   
       	} else {
       		$data = yelp_update_http_for_ssl( $data );
       		$response = json_decode( $data['body'] );
       	}
       	// Handle Yelp response data
       	return $response;
   
       }
   
       /**
        * Function update http for SSL
        *
        */
       function yelp_update_http_for_ssl( $data ) {
   
       	if ( ! empty( $data['body'] ) && is_ssl() ) {
       		$data['body'] = str_replace( 'http:', 'https:', $data['body'] );
       	} elseif ( is_ssl() ) {
       		$data = str_replace( 'http:', 'https:', $data );
       	}
       	$data = str_replace( 'http:', 'https:', $data );
   
       	return $data;
   
       }
       ```
   
 * And be sure to refresh the widget’s cache.
 *  Thread Starter [nlitend1](https://wordpress.org/support/users/nlitend1/)
 * (@nlitend1)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346204)
 * Works Great! Thank you SO much! What a great plugin and dev.
 * Highly Recommend Yelp Widget Pro!
 *  Plugin Author [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * (@dlocc)
 * [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346207)
 * Great! I’d love a review if you get a moment: [https://wordpress.org/support/view/plugin-reviews/yelp-widget-pro](https://wordpress.org/support/view/plugin-reviews/yelp-widget-pro)
 * Marking this as resolved (fix will come out in next release).

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘HTTPS? Is it possible to get yelpcdn.com resources via https?’ is closed
to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/yelp-widget-pro_98b4c1.svg)
 * [Reviews Block for Yelp](https://wordpress.org/plugins/yelp-widget-pro/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/yelp-widget-pro/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/yelp-widget-pro/)
 * [Active Topics](https://wordpress.org/support/plugin/yelp-widget-pro/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/yelp-widget-pro/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/yelp-widget-pro/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Devin Walker](https://wordpress.org/support/users/dlocc/)
 * Last activity: [11 years, 8 months ago](https://wordpress.org/support/topic/https-is-it-possible-to-get-yelpcdncom-resources-via-https/#post-5346207)
 * Status: resolved