I’ m trying to show a Html page with a label. But I’m doing something wrong. This is a test that not work.

public class ThemeLayout extends CssLayout{
	Label label=new Label("",Label.CONTENT_XHTML);
	public  ThemeLayout() {
				"<style type='text/css'>" +
				  "body {" +
				    "color: purple;" +
				    "background-color: green }" +
				"</head>" +

				"<body>" +
				"TEST" +
				"</body>" +


Can someone tell me what is wrong?

Label with XHTML content will attach that content within the DOM tree that is already showing on the screen. So, you can’t attach a ‘full page’ with head and body to the DOM tree node.