-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcontrols.tpl
More file actions
77 lines (74 loc) · 3.48 KB
/
controls.tpl
File metadata and controls
77 lines (74 loc) · 3.48 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<!DOCTYPE html>
<html lang='en'>
<head profile="http://www.w3.org/2005/10/profile">
<title>Controls</title>
<meta charset="utf-8">
<link rel="icon" type="image/png" href="/static/img/favicon.png" />
<link rel="apple-touch-icon" href="/static/img/image.png" />
<link id='style' rel="stylesheet" href="/static/css/styles.css"/>
<script src="/static/js/script.js"></script>
<script src="/static/js/tinyeditor.js"></script>
</head>
<body>
<div id="blackHeader">
<a href="{{siteAddress[1]}}">{{siteAddress[0]}}</a>
<a href="{{blogAddress[1]}}">{{blogAddress[0]}}</a>
%for key in tags:
<a href="{{blogAddress[1]}}/tag/{{tags[key]}}">{{key}}</a>
%end
</div>
<div id="header"><H1><a href="{{blogAddress[1]}}" id="logo">{{pagename}}</a></H1></div>
<div id="main">
<div id="postSection" style="float:left;">
<form id="newPostForm" onsubmit="postEditor.post(); return textCheck()" action="{{blogAddress[1]}}/submitPost" method="post">
<input type="text" class="newpost" name="title" id="title" value="Title" onfocus="if (this.value=='Title') this.value=''; this.style.color = 'black'" onblur="afterBlur('title')" /><br />
<textarea class="newpost" name="post" id="post" style="text-align:justify; color:black; height:400px;"></textarea><br/>
<input type="text" class="newpost" name="tags" id="tags" value="Tags. Please separate tags with coma" onfocus="if (this.value=='Tags. Please separate tags with coma') this.value=''; this.style.color = 'black'" onblur="afterBlur('tags')" /><br />
<input type="date" readonly class="newpost" name="postDate" id="postDate" /><br />
Today's date <input type="checkbox" checked id="today" onclick="changeDate('Date: YYYY-MM-DD')"/>
<input name="submit" style="width:150px;" type="submit" value="Create post" />
</form>
<a href="{{blogAddress[1]}}/logout" style="position: relative; top: 20px;">Log out</a>
</div>
<div id="sideMenu">
<a style="color: grey;" href="#" onclick="showHide('postEditor','headerTagsEditor'); loadXMLDoc('{{blogAddress[1]}}/postListFrom','editPosts')">edit post</a> |
<a style="color: grey;" href="#" onclick="showHide('headerTagsEditor','postEditor')">edit header</a>
<div id="postEditor"></div>
<div id="headerTagsEditor">
<form id="addTagsToHeader" onsubmit="return checkTags()" action="{{blogAddress[1]}}/addTags" method="post" >
<textarea name="headerTags" id="headerTags" style="width: 150px; color:black; height:270px;">
%for tag in tags:
{{tag}}:{{tags[tag]}}
%end
</textarea><br />
<input name="submitTags" style="width:100px;" type="submit" value="Add tags" />
</form>
</div>
</div>
</div>
<script type="text/javascript">
getDate('postDate');
postEditor = new TINY.editor.edit('editor',{
id:'post',
width:584,
height:350,
cssclass:'te',
controlclass:'tecontrol',
rowclass:'teheader',
dividerclass:'tedivider',
controls:['bold','italic','underline','strikethrough','|','subscript','superscript','|',
'orderedlist','unorderedlist','|','outdent','indent','|','leftalign',
'centeralign','rightalign','blockjustify','|','unformat','|','undo','redo','n',
'font','size','style','|','image','hr','link','unlink','|','cut','copy','paste','print'],
footer:true,
fonts:['Verdana','Arial','Georgia','Trebuchet MS'],
xhtml:true,
cssfile:'/static/css/styles.css',
bodyid:'editor',
footerclass:'tefooter',
toggle:{text:'source',activetext:'wysiwyg',cssclass:'toggle'},
resize:{cssclass:'resize'}
});
</script>
</body>
</html>