Merge pull request #1327 from rog1121/next

Add CLEditor to News
This commit is contained in:
Sebastian Grewe 2014-01-10 00:27:54 -08:00
commit d16b5a1067
7 changed files with 1221 additions and 5 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 68 B

View File

@ -0,0 +1,24 @@
.cleditorMain {border:1px solid #999; padding:0 1px 1px; background-color:white}
.cleditorMain iframe {border:none; margin:0; padding:0}
.cleditorMain textarea {border:none; margin:0; padding:0; overflow-y:scroll; font:10pt Arial,Verdana; resize:none; outline:none /* webkit grip focus */}
.cleditorToolbar {background: url('images/toolbar.gif') repeat}
.cleditorGroup {float:left; height:26px}
.cleditorButton {float:left; width:24px; height:24px; margin:1px 0 1px 0; background: url('images/buttons.gif')}
.cleditorDisabled {opacity:0.3; filter:alpha(opacity=30)}
.cleditorDivider {float:left; width:1px; height:23px; margin:1px 0 1px 0; background:#CCC}
.cleditorPopup {border:solid 1px #999; background-color:white; color:#333333; position:absolute; font:10pt Arial,Verdana; cursor:default; z-index:10000}
.cleditorList div {padding:2px 4px 2px 4px}
.cleditorList p,
.cleditorList h1,
.cleditorList h2,
.cleditorList h3,
.cleditorList h4,
.cleditorList h5,
.cleditorList h6,
.cleditorList font {padding:0; margin:0; background-color:Transparent}
.cleditorColor {width:150px; padding:1px 0 0 1px}
.cleditorColor div {float:left; width:14px; height:14px; margin:0 1px 1px 0}
.cleditorPrompt {background-color:#F6F7F9; padding:4px; font-size:8.5pt}
.cleditorPrompt input,
.cleditorPrompt textarea {font:8.5pt Arial,Verdana;}
.cleditorMsg {background-color:#FDFCEE; width:150px; padding:4px; font-size:8.5pt}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

View File

@ -1,3 +1,8 @@
<script src="{$PATH}/js/cleditor/jquery.cleditor.min.js"></script>
<link rel="stylesheet" href="{$PATH}/js/cleditor/jquery.cleditor.css">
<script type="text/javascript">
$(document).ready(function () { $(".cleditor").cleditor(); });
</script>
<article class="module width_full">
<header><h3>News Posts</h3></header>
<ul><li>News posts support the Markdown syntax</li></ul>
@ -10,10 +15,8 @@
<label>Header</label>
<input size="30" type="text" name="data[header]" required />
</fieldset>
<fieldset>
<label>Content</label>
<textarea name="data[content]" rows="5" required></textarea>
</fieldset>
<label>Content</label>
<textarea class="cleditor" name="data[content]" rows="5" required></textarea>
</div>
<footer>
<div class="submit_link">

View File

@ -1,3 +1,8 @@
<script src="{$PATH}/js/cleditor/jquery.cleditor.min.js"></script>
<link rel="stylesheet" href="{$PATH}/js/cleditor/jquery.cleditor.css">
<script type="text/javascript">
$(document).ready(function () { $(".cleditor").cleditor(); });
</script>
<article class="module width_full">
<header><h3>Edit news entry #{$NEWS.id}</h3></header>
<form method="POST" action="{$smarty.server.PHP_SELF}">
@ -20,7 +25,7 @@
</tr>
<tr>
<th>Content</th>
<td><textarea name="content" rows="15" cols="150" type="text" required>{nocache}{$NEWS.content}{/nocache}</textarea></td>
<td><textarea class="cleditor" name="content" rows="15" cols="150" type="text" required>{nocache}{$NEWS.content}{/nocache}</textarea></td>
</tr>
</table>
<footer>