Ignore:
Timestamp:
Sep 6, 2010, 9:10:49 PM (14 years ago)
Author:
nikrou
Message:

Add IT thanks to sergix
Add CZ thanks to webprostor-hosting
Bug fix : Flash animation didn't work when category used a permanink.
Update FSF address
Remove configuration when plugin is uninstalled.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/photoWidget/include/photoWidgetContent.class.php

    r5647 r6850  
    1616// | You should have received a copy of the GNU General Public License     |
    1717// | along with this program; if not, write to the Free Software           |
    18 // | Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, |
    19 // | USA.                                                                  |
     18// | Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,            |
     19// | MA 02110-1301 USA.                                                    |
    2020// +-----------------------------------------------------------------------+
    2121
     
    2727    $this->plugin_config = $config;
    2828
    29     $this->fmt_xml = make_index_url() . '/category/%d/pw.xml';
    30     $xml_pattern = '`category/(\d*)/pw\.xml$`';
     29    $this->fmt_xml = make_index_url() . '/category/%s/pw.xml';
     30    $xml_pattern = '`category/([^/]*)/pw\.xml$`';
    3131   
    3232    if (preg_match($xml_pattern, $_SERVER['QUERY_STRING'], $matches)) {
     
    7171
    7272    $template->set_filename('index_thumbnails', PW_TEMPLATE . '/animation.tpl');
    73     $template->assign('PW_XML', sprintf($this->fmt_xml, $page['category']['id']));
     73    if (!empty($page['category']['permalink'])) {
     74      $template->assign('PW_XML', sprintf($this->fmt_xml, $page['category']['permalink']));
     75    } else {
     76      $template->assign('PW_XML', sprintf($this->fmt_xml, $page['category']['id']));
     77    }
    7478    $template->assign('PW_BGCOLOR', $this->plugin_config->pw_bgcolor);
    7579    $template->assign('PW_WIDTH', $this->plugin_config->pw_width);
Note: See TracChangeset for help on using the changeset viewer.