Changeset 171

Show
Ignore:
Timestamp:
01/12/08 16:00:14 (5 years ago)
Author:
d0nut
Message:

tagging sitemaps package can use seo urls - released 1.1.0

Location:
taggingreloaded/optionals
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • taggingreloaded/optionals/de.easy-coding.wcf.sitemaps.taggingreloaded/files/lib/system/event/listener/TaggingReloadedSitemapsPageListener.class.php

    r78 r171  
    22// wcf imports 
    33require_once(WCF_DIR.'lib/system/event/EventListener.class.php'); 
     4 
     5require_once(WCF_DIR.'lib/page/PublicSEORewriterTagging.class.php'); 
    46 
    57/** 
     
    1719        protected $eventObj; 
    1820        protected $className; 
     21        protected $rewriter; 
    1922 
    2023        /** 
     
    2427                $this->eventObj = $eventObj; 
    2528                $this->className = $className; 
     29                $this->rewriter = new PublicSEORewriterTagging(); 
    2630 
    2731                switch ($eventName) { 
     
    8791                        $tpl = '<url><loc>'.PAGE_URL.'/%s</loc></url>';  
    8892                        foreach($this->tags as $tag) { 
    89                                 printf($tpl, 'index.php?page=Tagging&amp;tag='.urlencode($tag)); 
     93                                printf($tpl, $this->rewriter->publicParseTagURLs($tag)); 
    9094                        } 
    9195                } 
  • taggingreloaded/optionals/de.easy-coding.wcf.sitemaps.taggingreloaded/package.xml

    r94 r171  
    55                <packagename><![CDATA[Sitemaps for Tagging Reloaded]]></packagename> 
    66                <packagedescription><![CDATA[XML Sitemaps for Tagging Reloaded.]]></packagedescription> 
    7                 <version>1.0.0</version> 
    8                 <date>2007-11-19</date> 
     7                <version>1.1.0</version> 
     8                <date>DATE</date> 
    99                <plugin>com.woltlab.wcf</plugin> 
    1010        </packageinformation> 
     
    2525                <eventlistener>eventlistener.xml</eventlistener> 
    2626        </instructions> 
     27         
     28        <instructions type="update" fromversion="1.0.0"> 
     29                <files>files.tar</files> 
     30        </instructions> 
    2731</package> 
  • taggingreloaded/optionals/de.easy-coding.wcf.taggingreloaded.seo/files/lib/system/event/listener/TaggingReloadedSEOOptionFormListener.class.php

    r170 r171  
    3636                                if (!empty($existingContent)) { 
    3737                                        $this->write($existingContent); 
    38                                 }                                
     38                                } 
    3939                                 
    40                                 $file->write("\n# WCF-SEO-TAGGING-START\n"); 
    41                                 $file->write("RewriteRule ^tags/(.+)$ index.php?page=Tagging&tag=$1 [L,QSA]"); 
    42                                 $file->write("\n# WCF-SEO-TAGGING-END\n"); 
     40                                if($options['SEO_REWRITE_TAGGING']) { 
     41                                        $localstring = str_replace('{TAG}', '(.+)', $options['SEO_REWRITE_TAGGING_FORMAT']); 
     42                                        $file->write("\n# WCF-SEO-TAGGING-START\n"); 
     43                                        $file->write("RewriteRule ^$localstring$ index.php?page=Tagging&tag=$1 [L,QSA]"); 
     44                                        $file->write("\n# WCF-SEO-TAGGING-END\n"); 
     45                                } 
    4346                                $file->close();                  
    4447                        }