Project

General

Profile

Actions

Bug #47274

closed

Tab key in Chrome inserts weird SPAN tags

Added by Florian Seirer over 11 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
RTE (rtehtmlarea + ckeditor)
Target version:
-
Start date:
2013-04-16
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
4.7
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

IE9 and Firefox 17 don't. They just jump to the next element in the browser.

On the other hand, Google Chrome inserts

<span class="Apple-tab-span" style="white-space:pre">    </span>
when you press the tabulator key while typing inside the editor.

I was actually expecting the browser to insert a blockquote tag or something similar. Apparently, this doesn't happen if the editor is configured to not use the indent and outdent buttons.

Either way, the behaviour should be equal among all browsers.

This is my RTE configuration:

RTE {
  default {
    logDeprecatedProperties.logAlsoToBELog = 1
    defaultContentLanguage = de
    enableWordClean.HTMLparser < RTE.default.proc.entryHTMLparser_db
    removeComments = 1
    removeTrailingBR = 1
    removeTags = address,area,article,aside,at,b,base,basefont,bdi,bdo,big,body,br,button,canvas,caption,center,cite,code,col,colgroup,command,datalist,dd,del,details,dfn,dialog,dir,div,dl,dt,em,fieldset,figcaption,figure,font,footer,frame,frameset,h1,h5,h6,head,header,hgroup,html,i,iframe,img,input,ins,isindex,kbd,keygen,label,legend,link,map,mark,menu,meta,meter,nav,nobr,object,optgroup,option,output,param,pre,progress,psonormal,q,rp,rt,ruby,s,samp,sdfield,section,select,small,source,strike,strong,summary,textarea,time,title,track,tt,u,var,wbr
    removeTagsAndContents = applet,audio,embed,form,noframes,noscript,style,script,video,o:lock,v:shape,v:shapetype,v:stroke,v:f,v:imagedata,v:stroke,v:path,v:formulas,v:shadow,v:group,w:wrap,o:p
    showButtons = *
    toolbarOrder = undo,redo,copy,cut,paste,pastetoggle,pastebehaviour,findreplace,link,unlink,acronym,line,insertcharacter,subscript,superscript,unorderedlist,orderedlist,citation,quotation,bar,chMode,linebreak,formatblock,blockstyle,textstyle
    buttons {
      acronym.pages = 1965
      formatblock {
        removeItems = address,article,div,section,footer,header,nav,aside,pre,h1,h5,h6
        postfixLabelWithTag = 1
        width = 140
      }
      indent {
        useBlockquote = 1
      }
      link {
        popupSelector.disabled = 1
        targetSelector.disabled = 1
        properties.class.allowedClasses = 
      }
      blockstyle {      
        tags.p.allowedClasses =  warning,info,error,success        
        width = 120
      }
      textstyle {
        tags.span.allowedClasses := addToList(regierungsmitglied)
        showTagFreeClasses = 1
        width = 150
      }
      pastetoggle.setActiveOnRteOpen = 1
    }    
    proc {    
      allowedClasses := addToList(regierungsmitglied,info,warning,error,success)
      allowedClasses := removeFromList(csc-frame-frame1, csc-frame-frame2, important, name-of-person, detail, MsoNormal)
      entryHTMLparser_db.tags {
        span.fixAttrib.style.unset = 1
        span.rmTagIfNoAttrib = 1
        p.fixAttrib.style.unset = 1
        p.fixAttrib.align.unset >
        p.fixAttrib.class.list = 
        p.fixAttrib.class.trim = MsoNormal
        a.fixAttrib.onmouseover.unset = 1
        a.fixAttrib.onmouseout.unset = 1
        div.fixAttrib.style.unset = 1
        em.fixAttrib.style.unset = 1
        ol.fixAttrib.start.unset = 1
        ol.fixAttrib.type.unset = 1
        ol.fixAttrib.style.unset = 1
        ul.fixAttrib.start.unset = 1
        ul.fixAttrib.type.unset = 1
        li.fixAttrib.class.unset = 1
        li.fixAttrib.style.unset = 1
        strong.fixAttrib.style.unset = 1
        table.fixAttrib.class.unset = 1
        table.fixAttrib.style.unset = 1
        table.fixAttrib.border.unset = 1
        table.fixAttrib.cellpadding.unset = 1
        table.fixAttrib.cellspacing.unset = 1
        th.fixAttrib.style.unset = 1
        tr.fixAttrib.style.unset = 1
        td.fixAttrib.style.unset = 1
        td.fixAttrib.width.unset = 1
        img.fixAttrib.usemap.unset = 1
      } 
    }
  }
  classes := removeFromList(csc-frame-frame1, csc-frame-frame2, important, name-of-person, detail) 
  classes {
    regierungsmitglied {
      name = Regierungsmitglied
      value = font-weight:bold;
    }    
    warning {    
      name = Warnung
      value = background-color:gold;
    }
    info {
      name = Information
      value = background-color:lightskyblue;
    }
    error {
      name = Fehler
      value = background-color:firebrick; color:white;
    }
    success {
      name = Erfolg
      value = background-color:forestgreen; color:white;
    }
  }
}

Actions #1

Updated by Gerrit Code Review over 11 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/20057

Actions #2

Updated by Stanislas Rolland over 11 years ago

The change will stop the event and prevent the default action in all browsers, if the indent/outdent buttons are not configured in the toolbar.

If you do not want to see the indent button in the toolbar, but still want to do the indent action by pressing the TAB key (although I do not know why one would want to do this nor do I think that it is a good isea), you could add the buttons to the toolbar but add the settings:
RTE.default.buttons.indent.hide = 1
RTE.default.buttons.outdent.hide = 1

Actions #3

Updated by Gerrit Code Review over 11 years ago

Patch set 1 for branch TYPO3_6-0 has been pushed to the review server.
It is available at https://review.typo3.org/20058

Actions #4

Updated by Stanislas Rolland over 11 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #5

Updated by Gerrit Code Review over 11 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_4-7 has been pushed to the review server.
It is available at https://review.typo3.org/20059

Actions #6

Updated by Stanislas Rolland over 11 years ago

  • Status changed from Under Review to Resolved
Actions #7

Updated by Gerrit Code Review over 11 years ago

  • Status changed from Resolved to Under Review

Patch set 1 for branch TYPO3_4-5 has been pushed to the review server.
It is available at https://review.typo3.org/20060

Actions #8

Updated by Stanislas Rolland over 11 years ago

  • Status changed from Under Review to Resolved
Actions #9

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF