$spec){ if($spec['name'] != ''){ $panels[$spec['name']] = array(); foreach($spec as $k => $v){ if($v != $spec['name']){ if($k == 'Efficiency (%)'){ for($i = 0; $i < sizeof($v); $i++){ $panels[$spec['name']][$k][] = ($v[$i] == '')? null :floatval($v[$i]); } }else{ $panels[$spec['name']][$k] = $v; } } } } } if(sizeof($panels) > 0){ update_option($plugin_slug.'panels', json_encode($panels)); }else{ delete_option($plugin_slug.'panels'); } echo '

Settings saved!

'; } $lang = get_option($plugin_slug.'language', 'en'); $Settings = array( 'lang' => $lang, 'country' => get_option($plugin_slug.'country', 'JP'), 'currency' => get_option($plugin_slug.'currency', null), 'area' => get_option($plugin_slug.'area', 50), 'price' => get_option($plugin_slug.'price', null), 'rooftop' => get_option($plugin_slug.'rooftop', null), 'texts' => json_decode(get_option($plugin_slug.'texts', json_encode(json_decode(file_get_contents(dirname(__FILE__).'/json/texts.json')) -> $lang))), 'panels' => json_decode(get_option($plugin_slug.'panels',json_encode(json_decode(file_get_contents(dirname(__FILE__).'/json/brands.json')) -> $lang))), 'map' => json_decode(get_option($plugin_slug.'map', file_get_contents(dirname(__FILE__).'/json/map.json'))), 'mapPosition'=> get_option($plugin_slug.'mapPosition', 'right'), 'buildingPolygonStyles' => json_decode(get_option($plugin_slug.'buildingPolygonStyles', file_get_contents(dirname(__FILE__).'/json/buildingPolygonStyles.json'))), 'drawnPolygonStyles' => json_decode(get_option($plugin_slug.'drawnPolygonStyles', file_get_contents(dirname(__FILE__).'/json/drawnPolygonStyles.json'))), 'adminLanguages' => json_decode(file_get_contents(dirname(__FILE__).'/json/admin.texts.json')) ); $langs = array( "en" => "English", "ja" => "日本語", "es" => "Español", "fr" => "Français", "zh" => "简体中文" ); $countries = json_decode(file_get_contents(dirname(__FILE__).'/json/config.json'),true); $countriesByName = $countries; uasort($countriesByName, function ($a, $b) { return strcmp($a['country'], $b['country']);}); $countriesByName = json_decode(json_encode($countriesByName)); $countriesByCurrency = $countries; uasort($countriesByCurrency, function ($a, $b) { return strcmp($a['country'], $b['country']);}); $countriesByCurrency = json_decode(json_encode($countriesByCurrency)); function get_contrast_color($bgColor) { $r = $g = $b = 0; if (strpos($bgColor, '#') === 0) { $hex = substr($bgColor, 1); if (strlen($hex) === 3) { $hex = preg_replace('/(.)/', '$1$1', $hex); } $r = hexdec(substr($hex, 0, 2)); $g = hexdec(substr($hex, 2, 2)); $b = hexdec(substr($hex, 4, 2)); } elseif (strpos($bgColor, 'rgb') === 0) { preg_match_all('/\d+/', $bgColor, $matches); list($r, $g, $b) = array_map('intval', $matches[0]); } else { return '#000000'; } $luminance = (0.299 * $r + 0.587 * $g + 0.114 * $b) / 255; return $luminance > 0.5 ? '#000000' : '#FFFFFF'; } ?>

Solar Energy Simulator Settings

🔆 Plugin Overview: Solar Installation Value Simulator

Solar Installation Value Simulator is a practical and user-friendly WordPress plugin that enables users to estimate the annual financial value of solar panel installations. The plugin calculates the estimated installation value by multiplying the annual power output of the solar panels by the prevailing electricity price in the user's region.

🖥️ Example

Here is a link to the Example used in Wordpress.

🎯 Key Features

⚙️ How to Use

After installing the plugin, navigate to the Solar Installation Simulator settings in your WordPress admin panel to configure default values and appearance options.

To display the simulator on any page or post, simply insert the shortcode:

[solar_energy_simulator]

📌 Intended Users

This plugin is ideal for homeowners, energy consultants, solar product vendors, and developers interested in evaluating or promoting solar energy savings.

📝 License

This plugin is licensed under the MIT License.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND.

Important: The license above applies to the plugin source code only. All data retrieved from our Data API is licensed separately. Use of API data is subject to separate terms of service.

🌐 Data Usage

All data retrieved from our Data API is not included in the MIT license. It is provided separately under our terms of service. This includes building data sourced from Overture. These datasets are subject to their own terms of service and licensing. The GHI (Global Horizontal Irradiance) data is used internally for calculations and is not delivered to users. It is sourced from World - Global Horizontal Irradiation (GHI) GIS Data, (Global Solar Atlas) and published under the CC BY 4.0.

💬 We'd Love to Hear From You

Your feedback is important to us. If you have any questions, feature requests, or suggestions, please reach out via the plugin support page or contact us directly. Your input helps us make this tool even better.

Feel free to contact us or info@otani.co

    texts -> $lang as $k => $v){ ?>
    $spec){ ?>
  • ×
      $v){ ?>
    • brands -> $lang -> $k; ?>
Add
    $paint){ ?>
  • buildingPolygonStyles -> $lang -> subtitles -> $layer; ?>
      $v){ ?>
    • buildingPolygonStyles -> $lang -> keys -> $k; ?>
    $paint){ ?>
  • drawnPolygonStyles -> $lang -> subtitles -> $layer; ?>
      $v){ ?>
    • drawnPolygonStyles -> $lang -> keys -> $key; ?> ">

By using this plugin, you agree to the Terms of Service and Privacy Policy, inlucding Cookie Use.