1

Include zul just with head elements

asked 2015-05-16 23:41:01 +0800

cgraf gravatar image cgraf
22 3

updated 2015-05-16 23:46:26 +0800

Hello,

Is it possible to create a zul file with head elements (meta, link, etc) that can be included in all other zul pages? For example, I have the following code:

<?meta charset="utf-8" ?>
<?meta name="viewport"    content="width=device-width, initial-scale=1.0" ?>
<?meta name="description" content="" ?>
<?meta name="author"      content="cgraf" ?>
<?link rel="shortcut icon" href="/assets/images/icone-intelidata.ico" ?>
<?link href="bootstrap/css/bootstrap.css" rel="stylesheet" type="text/css"?>
<?link rel="stylesheet" href="/assets/css/font-awesome.min.css"?>
<?link rel="stylesheet" href="/assets/css/main.css" ?>

This code is the same into all pages.. so I do not want to repeat it every page. I tried to use <?include but it doesnt works...

Thanks cgraf

delete flag offensive retag edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2015-05-17 07:14:04 +0800

chillworld gravatar image chillworld flag of Belgium
5337 4 9
https://github.com/chillw...

This is possible but you don't need to use include but you need to make usage of import.

Greetz chill.

link publish delete flag offensive edit

Comments

It works, thank you. The only strange thing, the documentation mentions <?import uri="..." ?> but in fact, it works with <?import src="..." ?>

cgraf ( 2015-05-18 05:32:59 +0800 )edit

You can click on I'm stuck here and give feedback that it works with src and not uri

chillworld ( 2015-05-18 06:31:05 +0800 )edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
2 followers

RSS

Stats

Asked: 2015-05-16 23:41:01 +0800

Seen: 38 times

Last updated: May 17 '15

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More