Forums / General / tag "tr" attribute problem

tag "tr" attribute problem

Author Message

source pixel

Tuesday 24 July 2007 4:19:55 am

Hi

Problem with class attribute of tag "<tr>" with "Online editor" switched on

I have created such a table with "Online editor"

Example:

<table class="table_style"  border="0" cellpadding="2" cellspacing="0"  width="200">
  <tr class="tr_style1">
    <td class="td_style1">1</td>
    <td class="td_style1">2</td>
    <td class="td_style1">3</td>
  </tr>
  <tr class="tr_style2">
    <td>4</td>
    <td>5</td>
    <td>6</td>
  </tr>
</table>

After next editing tags "<tr>" lose class attribute.
so instead of <tr class="tr_style1"> we get <tr>

But if online editor is off attribute don't disappear.

Help to solve the problem.

Xavier Serna

Tuesday 24 July 2007 5:57:22 am

You need to configure the styles that you want to use for each element (in this case tr), in and override for content.ini. And then assign the styles to each element in the OE.

An example:

[tr]
AvailableClasses[]
AvailableClasses[]=myTRstyle1
AvailableClasses[]=myTRstyle2

for more reference see the default content.ini file, inside settings.

hth!

--
Xavier Serna
eZ Publish Certified Developer
Departament de Software
Microblau S.L. - http://www.microblau.net
+34 937 466 205

source pixel

Wednesday 25 July 2007 12:12:40 am

Hi, Thanks for the answer.
Yes I have written so in a configuration file (content.ini.append.php),

<?php /* #?ini charset="utf-8"?

[tr]
AvailableClasses[]=tr_style1
AvailableClasses[]=tr_style2

[td]
AvailableClasses[]=td_style1
AvailableClasses[]=td_style2

[table]
AvailableClasses[]
AvailableClasses[]=table_style
*/ ?>

I have created such a table with "Online editor"

Example:

<table class="table_style"  border="1" cellpadding="2" cellspacing="0"  width="100%">
    <tr class="tr_style1">
       <td valign="top" class="td_style1">  
          <p>
            1
         </p>
      </td>
       <td valign="top" class="td_style1">  
          <p>
            2
         </p>
      </td>
   </tr>
    <tr class="tr_style2">
      <td valign="top" class="td_style2">  
         <p>
           3
         </p>
     </td>
      <td valign="top" class="td_style2">  
         <p>
           4
        </p>
    </td>
   </tr>
</table>

<b>After next editing tags "<tr class="tr_style1">" lose class attribute, we get "<tr>"</b>

<textarea class="box" name="ContentObjectAttribute_data_text_844" cols="90" rows="10">
&lt;p&gt;&lt;table id='table' class='table_style' width='100%' ezborder='1' border='1'&gt;&lt;tr&gt;&lt;td class='td_style1'&gt;&lt;p&gt;1&lt;/p&gt;&lt;/td&gt;&lt;td class='td_style1'&gt;&lt;p&gt;2&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td class='td_style2'&gt;&lt;p&gt;3&lt;/p&gt;&lt;/td&gt;&lt;td class='td_style2'&gt;&lt;p&gt;4&lt;/p&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;
</textarea>
<p><table id='table' class='table_style' width='100%' ezborder='1' border='1'><tr><td class='td_style1'><p>1</p></td><td class='td_style1'><p>2</p></td></tr><tr><td class='td_style2'><p>3</p></td><td class='td_style2'><p>4</p></td></tr></table></p><p>&nbsp;</p>

<b>but the problem is not solved.

Help to solve the problem.</b>

Kristof Coomans

Thursday 26 July 2007 2:30:24 am

Hi, can you tell us which version of
- eZ publish
- Online Editor
you are using?

Does the same issue happen when the online editor is disabled?

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

source pixel

Thursday 26 July 2007 3:45:02 am

Hi

- eZ publish: 3.9.0 (3.9.0)
- Online Editor: 4.2

If I switch off Online Editor, a class in tag "<tr class="tr_style1">" attribute will work.

Kristof Coomans

Thursday 26 July 2007 5:46:38 am

I can confirm the wrong behavior in Mozilla Firefox (2.0.0.5), with OE 4.2.3. Can you please report this in the issue tracker ( http://issues.ez.no/ProjectSelect.php?Id=4 ) and crosslink with this forum topic?

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

eZ debug

Timing: Jan 30 2025 21:45:50
Script start
Timing: Jan 30 2025 21:45:50
Module start 'content'
Timing: Jan 30 2025 21:45:50
Module end 'content'
Timing: Jan 30 2025 21:45:50
Script end

Main resources:

Total runtime0.2290 sec
Peak memory usage8,192.0000 KB
Database Queries141

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0079 587.9063370.3047
Module start 'content' 0.00790.0149 958.21091,009.5938
Module end 'content' 0.02280.2061 1,967.80473,898.6875
Script end 0.2289  5,866.4922 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00462.0059200.0002
Check MTime0.00130.5675200.0001
Mysql Total
Database connection0.00090.399710.0009
Mysqli_queries0.123153.78431410.0009
Looping result0.00170.75461390.0000
Template Total0.205889.910.2058
Template load0.00080.335410.0008
Template processing0.205089.554110.2050
Override
Cache load0.00060.249010.0006
Sytem overhead
Fetch class attribute can translate value0.00190.813710.0019
XML
Image XML parsing0.00030.118410.0003
General
dbfile0.00843.6557200.0004
String conversion0.00000.003030.0000
Note: percentages do not add up to 100% because some accumulators overlap

CSS/JS files loaded with "ezjscPacker" during request:

CacheTypePacklevelSourceFiles
CSS0extension/community/design/community/stylesheets/ext/jquery.autocomplete.css
extension/community_design/design/suncana/stylesheets/scrollbars.css
extension/community_design/design/suncana/stylesheets/tabs.css
extension/community_design/design/suncana/stylesheets/roadmap.css
extension/community_design/design/suncana/stylesheets/content.css
extension/community_design/design/suncana/stylesheets/star-rating.css
extension/community_design/design/suncana/stylesheets/syntax_and_custom_tags.css
extension/community_design/design/suncana/stylesheets/buttons.css
extension/community_design/design/suncana/stylesheets/tweetbox.css
extension/community_design/design/suncana/stylesheets/jquery.fancybox-1.3.4.css
extension/bcsmoothgallery/design/standard/stylesheets/magnific-popup.css
extension/sevenx/design/simple/stylesheets/star_rating.css
extension/sevenx/design/simple/stylesheets/libs/fontawesome/css/all.min.css
extension/sevenx/design/simple/stylesheets/main.v02.css
extension/sevenx/design/simple/stylesheets/main.v02.res.css
JS0extension/ezjscore/design/standard/lib/yui/3.17.2/build/yui/yui-min.js
extension/ezjscore/design/standard/javascript/jquery-3.7.0.min.js
extension/community_design/design/suncana/javascript/jquery.ui.core.min.js
extension/community_design/design/suncana/javascript/jquery.ui.widget.min.js
extension/community_design/design/suncana/javascript/jquery.easing.1.3.js
extension/community_design/design/suncana/javascript/jquery.ui.tabs.js
extension/community_design/design/suncana/javascript/jquery.hoverIntent.min.js
extension/community_design/design/suncana/javascript/jquery.popmenu.js
extension/community_design/design/suncana/javascript/jScrollPane.js
extension/community_design/design/suncana/javascript/jquery.mousewheel.js
extension/community_design/design/suncana/javascript/jquery.cycle.all.js
extension/sevenx/design/simple/javascript/jquery.scrollTo.js
extension/community_design/design/suncana/javascript/jquery.cookie.js
extension/community_design/design/suncana/javascript/ezstarrating_jquery.js
extension/community_design/design/suncana/javascript/jquery.initboxes.js
extension/community_design/design/suncana/javascript/app.js
extension/community_design/design/suncana/javascript/twitterwidget.js
extension/community_design/design/suncana/javascript/community.js
extension/community_design/design/suncana/javascript/roadmap.js
extension/community_design/design/suncana/javascript/ez.js
extension/community_design/design/suncana/javascript/ezshareevents.js
extension/sevenx/design/simple/javascript/main.js

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1pagelayout.tpl<No override>extension/sevenx/design/simple/templates/pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs