Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Apr 27th, 2012  |  syntax: PHP  |  size: 0.48 KB  |  views: 62  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
This paste has a previous version, view the difference. Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. <?php
  2. /*
  3.  Plugin Name: Secure Store (WordPress HTTPS)
  4.  Plugin URI: http://mvied.com/projects/wordpress-https/
  5.  Description: Uses WordPress HTTPS to secure URL's containing 'store'.
  6.  Author: Mike Ems
  7.  Version: 1.0
  8.  Author URI: http://mvied.com/
  9.  */
  10.  
  11. function store_force_ssl( $force_ssl, $post_id ) {
  12.     if ( strpos($_SERVER['REQUEST_URI'], 'store') !== false ) {
  13.         $force_ssl = true;
  14.     }
  15.     return $force_ssl;
  16. }
  17.  
  18. add_filter('force_ssl', 'store_force_ssl', 10, 2);
clone this paste RAW Paste Data