fo: entity referenced but not declared

前端 未结 1 1863
清歌不尽
清歌不尽 2021-01-20 10:24

I am getting the error \"entity 0slash was referenced but not declared\" whenever I try to convert .fo file to .pdf with apache fop 1.0

I found out you can declare e

1条回答
  •  生来不讨喜
    2021-01-20 11:16

    (NOTE: In my answer I'm using the "Oslash" (oh slash) instead of the "0slash" (zero slash) you have in your question. Since you can't begin an entity name with a digit, I'm assuming that the zero is a typo.)

    You have a couple of options:

    1. You can modify whatever is creating your XSL-FO to output hex references instead of the ISO entity references. In this instance Ø would be Ø.

    2. You can declare the entity in the internal subset of a DOCTYPE declaration.

    Here is a sample XSL-FO with the DOCTYPE added:

    
    
    ]>
    
        
            
                
            
        
        
            
              Hello World! Ø
            
        
    
    

    If you process this with FOP, you get: Hello World! Ø

    0 讨论(0)
提交回复
热议问题