Le vendredi 19 octobre 2007 ? 10:16:41, vous ?criviez :
HS> Marc wrote:
>> I try to write the attributes value of an element before it, but I don't
>> know exactly which attributes are on the element, and some attribute with
>> different style.
>> I try to use the ::attributes but in this case I have to use the three
>> division.
>> I'm not sure to explain me then I try to give a sample.
>> <Texte NomStyle="Essai" Numero="N23">ceci est un texte </Texte>
>> -->[Essai]{N23}ceci est un texte
>> <Texte NomStyle="Essai">ceci est un texte </Texte>
>> -->[Essai]ceci est un texte
>> <Texte Numero="N23">ceci est un texte </Texte>
>> -->{N23}ceci est un texte
>> I try to do
>> Texte[Numero]:before {
>> content: "{" attr(Numero) "}";
>> }
>> but in the first case this rule doesn't run, and if I have 3 attributes I
>> have to write all the combination.
HS> Yes, you need to write 3 combinations. What's the problem?
Sometimes I have more than 2 attributes!
HS> Texte[Numero]:before {
HS> content: "{" attr(Numero) "}";
HS> }
HS> Texte[NomStyle]:before {
HS> content: "[" attr(NomStyle) "]";
HS> }
HS> Texte[NomStyle][Numero]:before {
HS> content: "[" attr(NomStyle) "]{" attr(Numero) "}";
HS> }
>> something like :
>> Texte:before {
>> content:attributes();
>> }
HS> This should be sufficient. No need to add Texte::attributeXXX rules,
HS> unless you want to customize th contents of the generated Attributes Box.
>> Texte::attribute(Numero) {
>> content:attribute-label() " : " value-editor(attribute,attribute())
>> }
>> doesn't run but :
HS> Try:
HS> Texte::attribute("Numero") {
HS> content:attribute-label() " : " value-editor(attribute,attribute())
HS> }
I try it but the content doesn't run in this case I have to use :
attribute-content-left and in this case it's not a display inline, but when I
have 2 atributes, each attribute is on a line.
HS> Notice the quotes around Numero. These are needed because CSS
HS> identifiers are case-insensitive. Therefore ::attribute(Numero) is
HS> understood to be ::attribute(numero).
>> Texte::attribute{
>> attribute-content-left: attribute-label() " : " ;
>> attribute-content-middle : value-editor(attribute,attribute());
>> }
>> is ok.
>> I hope all this is clear.
HS> ---
HS> PS: Normally this level of support is reserved to Professional Edition
HS> customers.