[JAVAEETUTORIAL-268] Copyright header in XHTML files is sometimes inserted as the first line Created: 29/Apr/14  Updated: 15/Sep/14  Resolved: 15/Sep/14

Status: Closed
Project: javaeetutorial
Component/s: examples
Affects Version/s: 7.0.4
Fix Version/s: 7.0.5

Type: Bug Priority: Major
Reporter: Ian Evans Assignee: Kim Haase
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

For whatever reason, the license plugin for Maven sometimes inserts the copyright notice above the <?xml ... ?> header, which breaks JSF pages. The XML header has to be the first line of the file. The template.xhtml files appear to be affected more than others for mysterious reasons.

See, e.g., examples/persistence/address-book/src/main/webapp/template.xhtml in the latest bundle:

<!--

    Copyright (c) 2014 Oracle and/or its affiliates. All rights reserved.

    You may not modify, use, reproduce, or distribute this software except in
    compliance with  the terms of the License at:
    http://java.net/projects/javaeetutorial/pages/BerkeleyLicense

-->
<?xml version='1.0' encoding='UTF-8' ?> 
<!--

    Copyright (c) 2013 Oracle and/or its affiliates. All rights reserved.

    You may not modify, use, reproduce, or distribute this software except in
    compliance with  the terms of the License at:
    http://java.net/projects/javaeetutorial/pages/BerkeleyLicense

-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
...

Out of the box, you'll get runtime errors. Removing the first copyright header allows the app to run correctly.



 Comments   
Comment by Kim Haase [ 15/Sep/14 ]

We did a sweep and fixed these problems.

Generated at Sat Feb 13 17:12:36 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.