SHARE
TWEET

Untitled

a guest Feb 16th, 2020 279 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. //------------------------------------------------------------------------------
  3. // BlaatSchaap TextDomain
  4. //------------------------------------------------------------------------------
  5. load_plugin_textdomain('blaatschaap', false, basename( dirname( __FILE__ ) ) . '/languages' );
  6.  
  7. //------------------------------------------------------------------------------
  8. // Class Auto Loader
  9. //------------------------------------------------------------------------------
  10. /*
  11. if (!function_exists("blaat_autoloader")) {
  12.   function blaat_autoloader($class) {
  13.       include 'classes/' .$class . '.class.php';
  14.   }
  15.   spl_autoload_register('blaat_autoloader');
  16. }
  17. */
  18.  
  19.  
  20. //------------------------------------------------------------------------------
  21. // BlaatSchaap Plugins Page
  22. //------------------------------------------------------------------------------
  23. if (!function_exists("blaat_plugins_page")) {
  24.   function blaat_plugins_page(){
  25.     echo '<div class="wrap">';
  26.     echo '<h2>';
  27.     _e("BlaatSchaap Plugins","blaatschaap");
  28.     echo '</h2><div style="text-align:center;">
  29.                          <style>.blaat_plugins_table{text-align:left;}</style>';
  30.     _e("Thank you for using BlaatSchaap plugins.","blaatschaap");
  31.  
  32.     // ok, we need to detect installed plugins and so
  33.     if ( ! function_exists( 'get_plugins' ) ) {
  34.       require_once ABSPATH . 'wp-admin/includes/plugin.php';
  35.     }
  36.     $plugins = get_plugins();
  37.     function isBS($name){
  38.       return strpos($name, "BlaatSchaap") === 0;
  39.     }
  40.     echo "<p>";
  41.     _e("Installed BlaatSchaap plugins:","blaatschaap");
  42.     echo "</p>";
  43.     // TODO: bundle logo with plugin, also, resize logo
  44.     // But as all admin pages are going to be rewritten for the 0.5 release
  45.     // this should do it for now.
  46.     echo "<img src='http://www.blaatschaap.be/sheep.png' width=125>";
  47.     echo "<span style='display:inline-block;'><table class='blaat_plugins_table'>";
  48.     echo "<tr><th>";
  49.     _e("Plugin name:","blaatschaap");
  50.     echo "</th><th>";
  51.     _e("Plugin version:","blaatschaap");
  52.     echo "</th><th>";
  53.     _e("Status:","blaatschaap");
  54.     echo "</th></tr>";
  55.     foreach ($plugins as $file => $plugin) {
  56.      if (isBS($plugin['Name'])) {
  57.         echo "<tr><td>".$plugin['Name']."</td><td>".$plugin['Version']."</td><td>";
  58.         echo is_plugin_active($file) ? _e("active","blaatschaap") : _e("inactive","blaatschaap");
  59.         echo "</td></tr>";
  60.       }
  61.     }
  62.    
  63.     echo "</table></span><hr><div style='text-align:center;'>";
  64.     _e("Thank you for using one of my projects. I develop these projects in my free time. <br>Please donate to support development of the future versions of my projects. <br>Any donation is appreciated. Thanks a lot!<br>AndrĂ©","blaatschaap");
  65.     ?>
  66. <br><br>
  67.  
  68. <form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
  69. <input type="hidden" name="cmd" value="_s-xclick">
  70. <input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----MIIHRwYJKoZIhvcNAQcEoIIHODCCBzQCAQExggEwMIIBLAIBADCBlDCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb20CAQAwDQYJKoZIhvcNAQEBBQAEgYBIW71ta4F5JZx22IXfmQugDj1NMgUPL5YU0tiE630qAATviqTSLYPfd0YyKZlcyqUp4RQfXlOgtsdjaohseM+Z6hxWf6wkH9Z2xMPTPZHXxKm+QUSWpGI1USQeC94ZXYu4trSGqJVQ2dnEWe2YId6VYK3F+zlZ+vM76YVkcvnKMDELMAkGBSsOAwIaBQAwgcQGCSqGSIb3DQEHATAUBggqhkiG9w0DBwQIXnykYICpSIuAgaBqHIZ7Ya5nNLBxGtDBrm1aPeBsXUBBdgfJ56QiFQ6zZeZD5t2o2Fu5hZJGhMHVbhXxmKTRCNUUYA2Fxh87mtmtUhBOkO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2ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb22CAQAwDAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQUFAAOBgQCBXzpWmoBa5e9fo6ujionW1hUhPkOBakTr3YCDjbYfvJEiv/2P+IobhOGJr85+XHhN0v4gUkEDI8r2/rNk1m0GA8HKddvTjyGw/XqXa+LSTlDYkqI8OwR8GEYj4efEtcRpRYBxV8KxAW93YDWzFGvruKnnLbDAF6VR5w/cCMn5hzGCAZowggGWAgEBMIGUMIGOMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcTDU1vdW50YWluIFZpZXcxFDASBgNVBAoTC1BheVBhbCBJbmMuMRMwEQYDVQQLFApsaXZlX2NlcnRzMREwDwYDVQQDFAhsaXZlX2FwaTEcMBoGCSqGSIb3DQEJARYNcmVAcGF5cGFsLmNvbQIBADAJBgUrDgMCGgUAoF0wGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEHATAcBgkqhkiG9w0BCQUxDxcNMTUwMzE1MTg0NTAxWjAjBgkqhkiG9w0BCQQxFgQU+hzUkbeH8DgizAts9E7KsJAEfB4wDQYJKoZIhvcNAQEBBQAEgYBPiJkBlMMhvT0+lRcCNFF5vlE4RLdvSg0xA5VAaFcKz+fTbIaxpoP1IsyJYW2khqv3lzuyA8rIiWWnlSUJlOvlTeUeqWmK0OidIp6Gx6xSd86c1ApduVSGdXIwExS/dwCb49xrUvjGhkwzinWWe/gtggLn8+Z4FNIjjAwwE7tQ1w==-----END PKCS7-----
  71. ">
  72. <input type="image" src="https://www.paypalobjects.com/en_US/NL/i/btn/btn_donateCC_LG.gif" border="0" name="submit" alt="PayPal, de veilige en complete manier van online betalen.">
  73. <img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
  74. </form>
  75.  
  76.  
  77.       <table style="display:inline-block;">
  78.         <tr><td>Bitcoin</td><td>1NMv9ETkYrMeg53hN66egrFQ4tnaPLmM29</td></tr>
  79.         <tr><td>Litecoin</td><td>LVPQtPn93GaAeczhUSengQzkQNpe3pZjnT</td></tr>
  80.       </table>
  81.     </div>
  82.   </div>
  83. </div>
  84. <?php
  85.   }
  86. }
  87. //------------------------------------------------------------------------------
  88. if (!function_exists("blaat_page_registered")){
  89.   function blaat_page_registered($menu_slug){
  90.     global $_parent_pages;
  91.     return isset($_parent_pages[$menu_slug]) ;
  92.   }
  93. }
  94. //------------------------------------------------------------------------------
  95. if (!function_exists("blaat_page_select")) {
  96.   function blaat_page_select($item){
  97.     $pages = get_pages();
  98.     $blaat = "<select id='$item' name='$item'>";
  99.     foreach ( $pages as $page ) {
  100.       $pagename = $page->post_name;
  101.       $selected = (get_option($item)==$pagename) ? "selected='selected'" : "";
  102.       $option = "<option value='$pagename' $selected>";
  103.       $option .= $page->post_title;
  104.       $option .= "</option>";
  105.       $blaat .= $option;
  106.     }
  107.     $blaat .= "</select>";
  108.     return $blaat;
  109.   }
  110. }
  111. //-----------------------------------------------------------------------------
  112.  
  113.  
  114.  
  115. //------------------------------------------------------------------------------
  116.  
  117.  
  118. //------------------------------------------------------------------------------
  119.  
  120.  
  121. ?>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top