Changeset 1644
- Timestamp:
- 12/28/06 14:13:19 (22 months ago)
- Location:
- trunk/gregarius
- Files:
-
- 4 modified
-
admin/channels.php (modified) (2 diffs)
-
cls/categories.php (modified) (1 diff)
-
cls/channels.php (modified) (2 diffs)
-
util.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/gregarius/admin/channels.php
r1629 r1644 547 547 list($retcde, $retmsg) = add_channel($u__, $fid, $t__, $d__); 548 548 if ($retcde && count($c__)) { 549 __exp__submitTag($retcde, $c__,"'channel'");549 __exp__submitTag($retcde,utf_encode($c__),"'channel'"); 550 550 } 551 551 echo ($retcde<0 ?$retmsg:" OK")."</p></li>\n"; … … 642 642 643 643 rss_query($sql); 644 __exp__submitTag($cid, $tags,"'channel'");644 __exp__submitTag($cid,utf8_decode($tags),"'channel'"); 645 645 rss_invalidate_cache(); 646 646 $ret__ = CST_ADMIN_DOMAIN_CHANNEL; -
trunk/gregarius/cls/categories.php
r1561 r1644 35 35 $this->id = $id; 36 36 if (getConfig('rss.output.usemodrewrite')) { 37 $this->rlink = getPath().preg_replace("/[^a-zA-Z0-9_]/", "_", $name)."/";37 $this->rlink = $this -> makeFolderUrl($name); //.preg_replace("/[^a-zA-Z0-9_]/", "_", $name)."/"; 38 38 } else { 39 39 $this->rlink = getPath()."feed.php?vfolder=$id"; -
trunk/gregarius/cls/channels.php
r1561 r1644 130 130 $this->id = $id; 131 131 if (getConfig('rss.output.usemodrewrite')) { 132 $this->rlink = getPath().preg_replace("/[^a-zA-Z0-9_]/", "_", $name)."/";132 $this->rlink = $this -> makeFolderUrl($name); // getPath().preg_replace("/[^a-zA-Z0-9_]/", "_", $name)."/"; 133 133 } else { 134 134 $this->rlink = getPath()."feed.php?folder=$id"; … … 136 136 $this->isRootFolder = ($id == 0); 137 137 $this->rootList = $rootList; 138 } 139 140 function makeFolderUrl($fn) { 141 return getPath( 142 preg_replace('#\s#','_',sanitize($fn,RSS_SANITIZER_URL)) 143 ) .'/'; 138 144 } 139 145 -
trunk/gregarius/util.php
r1641 r1644 965 965 // moved from ajax.php 966 966 function __exp__submitTag($id,$tags,$type = "'item'") { 967 $tags = strip_tags($tags); 967 968 $ftags = utf8_encode( preg_replace(ALLOWED_TAGS_REGEXP,'', trim($tags))); 968 969 $tarr = array_slice(explode(" ",$ftags),0,MAX_TAGS_PER_ITEM); … … 980 981 continue; 981 982 } 983 $ttag = sanitize($ttag, 984 RSS_SANITIZER_NO_SPACES | RSS_SANITIZER_SIMPLE_SQL 985 ); 986 982 987 rss_query( "insert into ". getTable('tag') 983 988 . " (tag) values ('$ttag')", false );
