Merge pull request #2937 from rabuzarus/1811_jot_charackter_counter
frio: add a very simple character counter to the jot
This commit is contained in:
commit
ba24b1b651
3 changed files with 128 additions and 127 deletions
|
@ -1157,6 +1157,9 @@ section #jotOpen {
|
||||||
#profile-jot-wrapper button#jot-submit {
|
#profile-jot-wrapper button#jot-submit {
|
||||||
margin-top: 5px;
|
margin-top: 5px;
|
||||||
}
|
}
|
||||||
|
#profile-jot-wrapper #character-counter {
|
||||||
|
padding: 10px 15px;
|
||||||
|
}
|
||||||
|
|
||||||
/* ACL */
|
/* ACL */
|
||||||
/*#jot-modal-body {
|
/*#jot-modal-body {
|
||||||
|
|
|
@ -1,9 +1,7 @@
|
||||||
|
|
||||||
|
<script type="text/javascript" src="{{$baseurl}}/js/ajaxupload.js" ></script>
|
||||||
|
|
||||||
{{*<script language="javascript" type="text/javascript">*}}
|
<script type="text/javascript">
|
||||||
|
|
||||||
|
|
||||||
<script>
|
|
||||||
var editor=false;
|
var editor=false;
|
||||||
var textlen = 0;
|
var textlen = 0;
|
||||||
var plaintext = '{{$editselect}}';
|
var plaintext = '{{$editselect}}';
|
||||||
|
@ -26,6 +24,10 @@ function initEditor(cb){
|
||||||
});
|
});
|
||||||
$(".jothidden").show();
|
$(".jothidden").show();
|
||||||
if (typeof cb!="undefined") cb();
|
if (typeof cb!="undefined") cb();
|
||||||
|
$("#profile-jot-text").keyup(function(){
|
||||||
|
var textlen = $(this).val().length;
|
||||||
|
$('#character-counter').text(textlen);
|
||||||
|
});
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
tinyMCE.init({
|
tinyMCE.init({
|
||||||
|
@ -130,13 +132,9 @@ function enableOnUser(){
|
||||||
//$(this).val("");
|
//$(this).val("");
|
||||||
initEditor();
|
initEditor();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<script type="text/javascript" src="{{$baseurl}}/js/ajaxupload.js" ></script>
|
|
||||||
<script>
|
<script type="text/javascript">
|
||||||
var ispublic = '{{$ispublic}}';
|
var ispublic = '{{$ispublic}}';
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -38,7 +38,6 @@
|
||||||
<form id="profile-jot-form" action="{{$action}}" method="post">
|
<form id="profile-jot-form" action="{{$action}}" method="post">
|
||||||
<div id="profile-jot-wrapper">
|
<div id="profile-jot-wrapper">
|
||||||
<div>
|
<div>
|
||||||
<div id="character-counter" class="grey jothidden text-info pull-left"></div>
|
|
||||||
<!--<div id="profile-jot-desc" class="jothidden pull-right"> </div>-->
|
<!--<div id="profile-jot-desc" class="jothidden pull-right"> </div>-->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
@ -80,6 +79,7 @@
|
||||||
-->
|
-->
|
||||||
|
|
||||||
<li class="pull-right"><button class="btn btn-primary" id="jot-submit" type="submit" id="profile-jot-submit" name="submit" ><i class="fa fa-slideshare fa-fw"></i> {{$share}}</button></li>
|
<li class="pull-right"><button class="btn btn-primary" id="jot-submit" type="submit" id="profile-jot-submit" name="submit" ><i class="fa fa-slideshare fa-fw"></i> {{$share}}</button></li>
|
||||||
|
<li id="character-counter" class="grey jothidden text-info pull-right"></li>
|
||||||
<div id="profile-rotator-wrapper" style="display: {{$visitor}};" >
|
<div id="profile-rotator-wrapper" style="display: {{$visitor}};" >
|
||||||
<img id="profile-rotator" src="images/rotator.gif" alt="{{$wait}}" title="{{$wait}}" style="display: none;" />
|
<img id="profile-rotator" src="images/rotator.gif" alt="{{$wait}}" title="{{$wait}}" style="display: none;" />
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue