The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Auto Save Post Script not working

View previous topic View next topic Go down

In progress Auto Save Post Script not working

Post by prescott50 on June 6th 2015, 5:37 pm

The script is no longer saving post in progress

prescott50
Forumember

Posts : 58
Reputation : 0
Language : english
Location : United States

http://thecleanerslounge.forumotion.com

Back to top Go down

In progress Re: Auto Save Post Script not working

Post by APE on June 6th 2015, 6:30 pm

@prescott50 wrote:The script is no longer saving post in progress

Please give us the place you got the code from and the code you have so we can test it.

Note some codes are not hosted by us and there for we may not have the right to edit the codes if it has a copyright on it.





APE
Manager
Manager

Male Posts : 8319
Reputation : 716
Language : fluent in dork / mumbojumbo & English haha
Location : STUCK IN FORUMOTIONS SERVERS HELP ME !!!!!!

http://chatworld.forumotion.co.uk/

Back to top Go down

In progress Re: Auto Save Post Script not working

Post by prescott50 on June 6th 2015, 8:30 pm

Here's the code

$(function(){$(function(){

var saved = 1;

if($("#text_editor_textarea").length != 0){
$("input[type='submit'][name='post']").attr("disabled", true).css("opacity", "0.5");
$(".sceditor-container").after("<br/><div id='div_minchars_info'></div></div>");

var sceditor = $("#text_editor_textarea").sceditor("instance");
var str = sceditor.val();
var regex = new RegExp('\\w{' + saved + ',}\\b', 'g');
var str_arr = str.match(regex);
var str_len = str_arr == null ? 0 : str_arr.length;

if(str_len >= 1) $("input[type='submit'][name='post']").attr("disabled", false).css("opacity", "1");

sceditor.keyUp(function(e) {
str = sceditor.val();
str_arr = str.match(regex);
str_len = str_arr == null ? 0 : str_arr.length;
if(str_len >= 1) {
$("#div_minchars_info").html("Message saved");
$("input[type='submit'][name='post']").attr("disabled", false).css("opacity", "1");
}else{
$("#div_minchars_info").html("Message not saved");
$("input[type='submit'][name='post']").attr("disabled", true).css("opacity", "0.5");
}
});
}
})});

prescott50
Forumember

Posts : 58
Reputation : 0
Language : english
Location : United States

http://thecleanerslounge.forumotion.com

Back to top Go down

In progress Re: Auto Save Post Script not working

Post by APE on June 7th 2015, 2:30 am

your code is working for me on my site but only on the Quick Reply box you will need to turn some of your codes off and then try again.





APE
Manager
Manager

Male Posts : 8319
Reputation : 716
Language : fluent in dork / mumbojumbo & English haha
Location : STUCK IN FORUMOTIONS SERVERS HELP ME !!!!!!

http://chatworld.forumotion.co.uk/

Back to top Go down

In progress Re: Auto Save Post Script not working

Post by prescott50 on June 9th 2015, 4:48 pm

Thanks APE. The Quick Reply is not auto saving for me.

prescott50
Forumember

Posts : 58
Reputation : 0
Language : english
Location : United States

http://thecleanerslounge.forumotion.com

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum