Changeset 967

Show
Ignore:
Timestamp:
07/10/10 11:21:51 (2 months ago)
Author:
ort
Message:

якорь для cut'а

Location:
trunk
Files:
3 modified

Legend:

Unmodified
Added
Removed
  • trunk/engine/modules/text/Text.class.php

    r952 r967  
    5757                // Разрешённые параметры тегов           
    5858                $this->oJevix->cfgAllowTagParams('img', array('src', 'alt' => '#text', 'title', 'align' => array('right', 'left', 'center'), 'width' => '#int', 'height' => '#int', 'hspace' => '#int', 'vspace' => '#int')); 
    59                 $this->oJevix->cfgAllowTagParams('a', array('title', 'href', 'rel'));            
     59                $this->oJevix->cfgAllowTagParams('a', array('title', 'href', 'rel' => '#text', 'name' => '#text')); 
    6060                $this->oJevix->cfgAllowTagParams('cut', array('name')); 
    6161                $this->oJevix->cfgAllowTagParams('object', array('width' => '#int', 'height' => '#int', 'data' => '#link', 'type' => '#text')); 
     
    6464                // Параметры тегов являющиеся обязательными 
    6565                $this->oJevix->cfgSetTagParamsRequired('img', 'src'); 
    66                 $this->oJevix->cfgSetTagParamsRequired('a', 'href'); 
     66                //$this->oJevix->cfgSetTagParamsRequired('a', 'href'); 
    6767                // Теги которые необходимо вырезать из текста вместе с контентом 
    6868                $this->oJevix->cfgSetTagCutWithContent(array('script', 'iframe', 'style')); 
     
    7373                $this->oJevix->cfgSetTagChilds('object', 'embed', false, false); 
    7474                // Если нужно оставлять пустые не короткие теги 
    75                 $this->oJevix->cfgSetTagIsEmpty(array('param','embed')); 
     75                $this->oJevix->cfgSetTagIsEmpty(array('param','embed','a')); 
    7676                // Не нужна авто-расстановка <br> 
    7777                $this->oJevix->cfgSetTagNoAutoBr(array('ul','ol','object')); 
     
    205205                        $aMatch[3]=str_replace('[<n>]',"\r\n",$aMatch[3]);                               
    206206                        $sTextShort=$aMatch[1]; 
    207                         $sTextNew=$aMatch[1].' '.$aMatch[3]; 
     207                        $sTextNew=$aMatch[1].' <a name="cut"></a> '.$aMatch[3]; 
    208208                        if (preg_match('/^\s*name\s*=\s*"(.+)"\s*\/?$/Ui',$aMatch[2],$aMatchCut)) {                              
    209209                                $sTextCut=trim($aMatchCut[1]); 
  • trunk/templates/skin/developer/topic.tpl

    r957 r967  
    4949                        {$oTopic->getTextShort()} 
    5050                        {if $oTopic->getTextShort()!=$oTopic->getText()} 
    51                                 <a href="{$oTopic->getUrl()}" title="{$aLang.topic_read_more}"> 
     51                                <a href="{$oTopic->getUrl()}#cut" title="{$aLang.topic_read_more}"> 
    5252                                {if $oTopic->getCutText()} 
    5353                                        {$oTopic->getCutText()} 
  • trunk/templates/skin/new/topic_list.tpl

    r937 r967  
    5454                                        {$oTopic->getTextShort()} 
    5555                                        {if $oTopic->getTextShort()!=$oTopic->getText()} 
    56                                         <br><br>( <a href="{$oTopic->getUrl()}" title="{$aLang.topic_read_more}"> 
     56                                        <br><br>( <a href="{$oTopic->getUrl()}#cut" title="{$aLang.topic_read_more}"> 
    5757                                        {if $oTopic->getCutText()} 
    5858                                                {$oTopic->getCutText()}