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

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 16:27:13
Script start
Timing: Jan 18 2025 16:27:13
Module start 'layout'
Timing: Jan 18 2025 16:27:13
Module start 'content'
Timing: Jan 18 2025 16:27:14
Module end 'content'
Timing: Jan 18 2025 16:27:14
Script end

Main resources:

Total runtime0.7522 sec
Peak memory usage4,096.0000 KB
Database Queries68

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0054 588.9766153.4531
Module start 'layout' 0.00540.0025 742.429739.3750
Module start 'content' 0.00780.7430 781.8047625.2578
Module end 'content' 0.75090.0013 1,407.062516.1797
Script end 0.7522  1,423.2422 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00360.4723160.0002
Check MTime0.00150.2019160.0001
Mysql Total
Database connection0.00090.114510.0009
Mysqli_queries0.691791.9547680.0102
Looping result0.00060.0815660.0000
Template Total0.720495.820.3602
Template load0.00220.287220.0011
Template processing0.718295.482120.3591
Template load and register function0.00010.015610.0001
states
state_id_array0.00130.167010.0013
state_identifier_array0.00110.146420.0006
Override
Cache load0.00190.2592460.0000
Sytem overhead
Fetch class attribute can translate value0.00050.071630.0002
Fetch class attribute name0.00120.164180.0002
XML
Image XML parsing0.00110.146130.0004
class_abstraction
Instantiating content class attribute0.00000.002790.0000
General
dbfile0.00080.1102220.0000
String conversion0.00000.000640.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
6content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
12content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
5content/datatype/view/ezxmltags/literal.tpl<No override>extension/community/design/standard/templates/content/datatype/view/ezxmltags/literal.tplEdit templateOverride template
4content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
3content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 32
 Number of unique templates used: 7

Time used to render debug report: 0.0001 secs