1

Topic: FullPage Plugin : Default head content

I am using FullPage edit plugin . It adds head and html tags automatically as below which is fine . But I want to add some custom content to it.

Right now It just inserts following html

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

While I need folllowing by default.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<style>
body {background-color:#fff; font-family:Arial, Helvetica, sans-serif; font-size: small; margin:0; padding:5px 15px}
</style>
</head>

Is there any setting in tinymce or I can change any js files to get expected result ?

Last edited by sonesh (2011-06-07 00:21:05)

2

Re: FullPage Plugin : Default head content

sonesh,

You can easily add the meta Content Type if you set the parameter.
fullpage_default_encoding
http://tinymce.moxiecode.com/wiki.php/Plugin:fullpage

For the body styling, you are probably better off setting the body style using an oninit triggered function.

3

Re: FullPage Plugin : Default head content

Hi, I need to add link to css file, when editor has been initiated.

<head>
  <link type="text/css" rel="stylesheet" href="/css/custom-pages.css
</head>

I tried this

tinyMCE.DOM.setHTML(tinyMCE.activeEditor.dom.select('head'), '<link type="text/css" rel="stylesheet" href="/css/custom-pages.css" />');

but editor only apply styles to content and do not add link tag to head. Is some way to solve this problem?

Last edited by pahhan (2012-06-27 08:12:31)