.. You may want to use the usual include line. Uncomment and adjust the path. .. include:: ../Includes.txt ==================== EXT: Openweather API ==================== :Author: Christopher :Created: 2010-12-18T19:57:23 :Changed by: Andreas Kastl :Changed: 2014-01-03T16:44:50.480000000 :Classification: openweatherapi :Description: The keywords help with categorizing and tagging of the manuals. You can combine two or more keywords and add additional keywords yourself. Please use at least one keyword from both lists. If your manual is NOT in english, see next tab "language" ---- forEditors (use this for editors / german "Redakteure") forAdmins (use this for Administrators) forDevelopers (use this for Developers) forBeginners (manuals covering TYPO3 basics) forIntermediates (manuals going into more depth) forAdvanced (covering the most advanced TYPO3 topics) ---- :Keywords: weather, api, wetter.com, openweather, forEditors, forBeginners :Author: Andreas Kastl :Email: andreas.kastl@gmx.de :Language: en .. _img-1-img-2-EXT-Openweather-API: |img-1| |img-2| EXT: Openweather API ==================================== Extension Key: openweatherapi Language: en Version: 1.2.1 Keywords: weather, api, wetter.com, openweather, forEditors, forBeginners Copyright 2006-2014, Andreas Kastl, < `andreas.kastl@gmx.de `_ > This document is published under the Open Content License available from `http://www.opencontent.org/opl.shtml `_ The content of this document is related to TYPO3 \- a GNU/GPL CMS/Framework available from `www.typo3.org `_ .. _Table-of-Contents: Table of Contents ----------------- **`EXT: Openweather API 1 <#__RefHeading__5708_1738894311>`_** **`Introduction 3 <#__RefHeading__5710_1738894311>`_** `What does it do? 3 <#__RefHeading__463_413120346>`_ `Screenshots 3 <#__RefHeading__465_413120346>`_ **`Users manual 4 <#__RefHeading__467_413120346>`_** `Registration at wetter.com 4 <#__RefHeading__31507_818911409>`_ `Installation of the extension 6 <#__RefHeading__503_1790968535>`_ `Plugin content element 7 <#__RefHeading__505_1790968535>`_ **`Configuration 8 <#__RefHeading__31515_818911409>`_** `FAQ 8 <#__RefHeading__31517_818911409>`_ `Reference 8 <#__RefHeading__31519_818911409>`_ **`Known problems 10 <#__RefHeading__31525_818911409>`_** `Limitations of openweather API 10 <#__RefHeading__1713_167034767>`_ `Limitations of this extension 10 <#__RefHeading__1715_167034767>`_ **`To-Do list 11 <#__RefHeading__477_413120346>`_** **`ChangeLog 12 <#__RefHeading__31623_818911409>`_** .. _Introduction: Introduction ------------ .. _What-does-it-do: What does it do? ^^^^^^^^^^^^^^^^ This extension displays weather forecasts in a frontend plugin. The forecast information is based on the openweather API provided by wetter.com. More information about openweather API and related terms & conditions can be found at `http://www.wetter.com/apps\_und\_mehr/website/api/ `_ . .. _Screenshots: Screenshots ^^^^^^^^^^^ The extension displays weather forecast for three days (current + 2 days): |img-3| Users manual ------------ .. _Registration-at-wetter-com: Registration at wetter.com ^^^^^^^^^^^^^^^^^^^^^^^^^^ In order to use the extension you need to create an user account and project subscription at wetter.com. First go to `http://www.wetter.com/mein\_wetter/register/ `_ and create an user account: |img-4| Then log in and create a new subscription for your project at `http://www.wetter.com/apps\_und\_mehr/website/api/projekte/ `_ : |img-5| Please read the terms & conditions (AGB) of `www.wetter.com `_ carefully. The free API interface is currently limited to 10,000 requests per month. After submitting the registration form you find your project name(s) and related API key(s) in the list. You will need these properties later for the configuration of the extension. |img-6| Click on the project name to configure your subscription. In section “Vorhersageeinstellungen” you can configure the amount of forecasts (“Anzahl der Vorhersagetage”, from 1 to 3 days) and the forecast attributes (“Felder der Vorhersageantwort”). Please include at least the following attributes in your forecast settings. Otherwise some fields will remain empty in frontend. Please do not forget to hit the save button at the bottom (“Vorhersageeinstellungen speichern”) to save your settings. .. _img-7-Installation-of-the-extension: |img-7| Installation of the extension ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Installation of the Typo3 extension is very simple. Just download the extension from TER and install it. Then add the static TypoScript template of the openweatherapi extension to your site template: |img-8| Plugin content element ^^^^^^^^^^^^^^^^^^^^^^ Insert a content element of type “plugin” on your website and select the openweatherapi extension (Weather forecast). |img-9| Insert the corresponding values for the properties “Project name” and “API Key” from your wetter.com subscription (see section “Registration at wetter.com” above). In the field “City Code” enter the code of the location for which you want to display the weather forecast. To find the right city code just open the URL `http://www.wetter.com `_ and perform a search for your preferred location. The city code is displayed in the result URL, e.g. for Berlin it is DE0001020: |img-10| Save your plugin and open the corresponding page in frontend. Now you should see the weather forecast for your preferred location: |img-3| Configuration ------------- .. _FAQ: FAQ ^^^ .. _I-get-the-error-Custom-HTML-template-not-found-or-plugin-s-static-TypoScript-not-included-in-site-config-What-should-I-do: I get the error “Custom HTML template not found or plugin's static TypoScript not included in site config.” What should I do? """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Make sure that you included the static template of the extension “openweatherapi” in your site template (see section “Installation of the extension“). Another reason may be that you have overwritten the TypoScript property “templateFile” of the plugin and use your custom HTML template. In this case the plugin could not find the HTML file. Please check if the file exists. .. _I-get-the-error-Weather-forecast-is-currently-not-available-connection-error-What-does-this-mean: I get the error “Weather forecast is currently not available (connection error).”. What does this mean? """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" The plugin tried to download weather data from `http://api.wetter.com `_ by using CURL since your Typo3 installation seems to prefer CURL to access external URLs. But the download was not successful. Check if your hosting provider allows outgoing calls to `http://api.wetter.com `_ via CURL. .. _I-get-the-error-Weather-forecast-is-currently-not-available-data-retrieval-error-What-does-this-mean: I get the error “Weather forecast is currently not available (data retrieval error).”. What does this mean? """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" The plugin tried to download weather data from `http://api.wetter.com `_ but did not receive a valid XML response. Check if your hosting provider allows outgoing calls to `http://api.wetter.com `_ . .. _I-get-the-error-Weather-forecast-is-currently-not-available-API-error-What-does-this-mean: I get the error “Weather forecast is currently not available (API error).”. What does this mean? """""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" The plugin tried to download weather data from `http://api.wetter.com `_ and got a valid XML response. But it did not include valid forecast data. Check the properties of your plugin content element if these are correct, especially city code. .. _Some-fields-in-frontend-are-missing-e-g-wind-direction-Why: Some fields in frontend are missing (e.g. wind direction). Why? """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Please check your subscription at wetter.com (see section “Registration at wetter.com”). Make sure that all required attributes are configured correctly. Or check your custom HTML template if all relevant markers are included. .. _There-is-only-one-forecast-rendered-How-can-I-increase-the-amount-of-forecasts-to-e-g-3-days: There is only one forecast rendered. How can I increase the amount of forecasts to e.g. 3 days? """"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""" Please check your subscription at wetter.com (see section “Registration at wetter.com”) and update the amount of forecasts in your settings. .. _Reference: Reference ^^^^^^^^^ Reference of TypoScript options. .. ### BEGIN~OF~TABLE ### .. _templateFile: templateFile """""""""""" .. container:: table-row Property templateFile Data type string Description Path of the HTML template file to render the frontend output. Use your own template if you want to modify the output. Default EXT:openweatherapi/res/template.tmpl .. _openweatherUrl: openweatherUrl """""""""""""" .. container:: table-row Property openweatherUrl Data type string Description URL prefix of the openweather API forecast interface. Usually should not be changed. Select a different URL if you use for example a separate script that fetches the XML file from wetter.com. May be useful if your hosting provider does not allow outgoing requests to `http://api.wetter.com `_ and therefore you need to bypass this restriction by a proxy script with other URL destinations. Default http://api.wetter.com/forecast/weather .. _iconUrl: iconUrl """"""" .. container:: table-row Property iconUrl Data type string Description Path of the icon files for the weather forecast images. Usually should not be changed. Necessary files are provided by the extension. Default EXT:openweatherapi/res/ .. _projectName: projectName """"""""""" .. container:: table-row Property projectName Data type string Description Optional. Name of the project as registered at wetter.com if this should be set by TypoScript instead of plugin content element. Default .. _apiKey: apiKey """""" .. container:: table-row Property apiKey Data type string Description Optional. API key as registered at wetter.com if this should be set by TypoScript instead of plugin content element. Default .. _cityCode: cityCode """""""" .. container:: table-row Property cityCode Data type string Description Optional. City code as registered at wetter.com if this should be set by TypoScript instead of plugin content element. Default .. _strftime: strftime """""""" .. container:: table-row Property strftime Data type string Description Format of the date in frontend (PHP strftime syntax). Default %A, %d.%m.%Y .. ###### END~OF~TABLE ###### **Note** : the default CSS definitions for the extension are also part of the static TypoScript template of this extension. Overwrite the CSS definitions if needed. .. _Known-problems: Known problems -------------- .. _Limitations-of-openweather-API: Limitations of openweather API ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ The XML data fetched from openweather API contains several attributes. The wetter.com frontend allows individual selection and deselection of attributes for each project. Please make sure that all necessary attributes are included in your subscription (see section “Registration at wetter.com”). The amount of forecasts can also be changed for each wetter.com subscription. This setting also affects the number of forecast days displayed on your web site (see section “Registration at wetter.com”). The XML data includes some text attributes in German language only. Wetter.com does not provide a translation for that, e.g. text of weather conditions (“leicht bewölkt”, “wolkig”, etc.). .. _Limitations-of-this-extension: Limitations of this extension ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Openweather API provides all-day forecast data and individual forecast data for certain time frames per day in the XML file. The extension does not support the individual forecasts per day, e.g. 6:00 am, 11:00 am, 5:00 pm and 11:00 pm. Currently it supports only the all-day values. The extension uses normal Typo3 caching to limit requests to openweather API service and speedup frontend rendering. If you want to update weather forecasts more often you have to either disable caching or set the cache lifetime to a shorter interval for the page that includes the plugin. .. _To-Do-list: To-Do list ---------- None .. _ChangeLog: ChangeLog --------- .. ### BEGIN~OF~TABLE ### .. _1-2-1: 1.2.1 ^^^^^ .. container:: table-row Version 1.2.1 Changes Fallback for date attribute implemented. Thanks to Patrick Finkbeiner. .. _1-2-0: 1.2.0 ^^^^^ .. container:: table-row Version 1.2.0 Changes Typo3 CMS 6.x compatibility fix, status changed to stable. .. _1-1-0: 1.1.0 ^^^^^ .. container:: table-row Version 1.1.0 Changes Bugfixes and completion of documentation. .. _1-0-0: 1.0.0 ^^^^^ .. container:: table-row Version 1.0.0 Changes Initial version. .. ###### END~OF~TABLE ###### .. ######CUTTER_MARK_IMAGES###### .. |img-1| image:: img-1.png .. :align: left .. :border: 0 .. :height: 44 .. :id: graphics5 .. :name: graphics5 .. :vspace: 57 .. :width: 161 .. |img-2| image:: img-2.png .. :align: left .. |img-3| image:: img-3.png .. :align: left .. :border: 0 .. :height: 169 .. :id: Grafik1 .. :name: Grafik1 .. :width: 591 .. |img-4| image:: img-4.png .. :align: left .. :border: 0 .. :height: 303 .. :id: Grafik9 .. :name: Grafik9 .. :width: 350 .. |img-5| image:: img-5.png .. :align: left .. :border: 0 .. :height: 426 .. :id: Grafik2 .. :name: Grafik2 .. :width: 571 .. |img-6| image:: img-6.png .. :align: left .. :border: 0 .. :height: 224 .. :id: Grafik4 .. :name: Grafik4 .. :width: 570 .. |img-7| image:: img-7.png .. :align: left .. :border: 0 .. :height: 587 .. :id: Grafik8 .. :name: Grafik8 .. :width: 563 .. |img-8| image:: img-8.png .. :align: left .. :border: 0 .. :height: 255 .. :id: Grafik6 .. :name: Grafik6 .. :width: 581 .. |img-9| image:: img-9.png .. :align: left .. :border: 0 .. :height: 381 .. :id: Grafik3 .. :name: Grafik3 .. :width: 467 .. |img-10| image:: img-10.png .. :align: left .. :border: 0 .. :height: 30 .. :id: Grafik5 .. :name: Grafik5 .. :width: 492