-
Notifications
You must be signed in to change notification settings - Fork 0
/
newpost.html
86 lines (66 loc) · 2.03 KB
/
newpost.html
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
78
79
80
81
82
83
84
85
86
<html>
<head>
<title>FABE - Fricking Awesome Blog Engine</title>
<link rel="stylesheet" type="text/css" href="style.css" />
<link rel="stylesheet" type="text/css" href="http://yui.yahooapis.com/combo?2.8.0r4/build/editor/assets/skins/sam/simpleeditor.css">
<script src="http://yui.yahooapis.com/combo?2.8.0r4/build/yahoo-dom-event/yahoo-dom-event.js&2.8.0r4/build/container/container_core-min.js&2.8.0r4/build/element/element-min.js&2.8.0r4/build/editor/simpleeditor-min.js"></script>
<script>
var myEditor,Dom,Event;
function showEditor(control) {
Dom=YAHOO.util.Dom;
Event=YAHOO.util.Event;
var myConfig = {
width : '560px',
height : '280px',
dompath: false,
focusAtStart: true
};
myEditor = new YAHOO.widget.SimpleEditor(control,myConfig);
myEditor.render();
myEditor._defaultToolbar.titlebar=''
}
function preview(){
myEditor.saveHTML();
document.forms[0].submit();
}
function cancel(){ window.location.href="."; }
</script>
</head>
<body>
<div id="page">
<div id="head">
<h1><a href=".">FABE</a></h1>
<h2>Fricking Awesome Blog Engine</h2>
</div><!-- head -->
<div id="content">
<div id="side">
<div class="panel">
<h1>Actions</h1>
<ul>
<li><a href="javascript:preview()">Preview post</a></li>
<li><a href="javascript:cancel()" >Cancel edition</a></li>
</ul>
</div>
</div><!-- side -->
<div id="main">
<div class="post">
<h2>New Post</h2>
<form method="POST" action="preview" class="yui-skin-sam">
<input id="xtitle" name="xtitle" type="textbox" value="Enter the post title here..." />
<br>
<br>
<textarea id="xcontent" name="xcontent"></textarea>
<script>showEditor("xcontent");</script>
<!--style>yui-toolbar-group h3{display:none;}</style-->
</form>
<button onclick="preview()">Preview</button>
<button onclick="cancel()">Cancel</button>
</div><!-- post -->
</div><!-- Main -->
</div><!-- content -->
<div id="foot">
<p>© 2010 - WTFPL - FABE</p>
</div>
</div><!-- page -->
</body>
</html>