PM: Last sent message appears Hitskin_logo Hitskin.com

This is a Hitskin.com skin preview
Install the skinReturn to the skin page

The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.
2 posters

    PM: Last sent message appears

    avatar
    darki
    Forumember


    Posts : 254
    Reputation : 10
    Language : German, english

    Solved PM: Last sent message appears

    Post by darki April 30th 2015, 9:45 am

    Technical Details

    Forum version : phpBB3
    Position : Administrator
    Concerned browser(s) : Other
    Who the problem concerns : All members
    Forum link : ( link is hidden, you must reply to see )

    Description of problem

    Hello,

    by using PM system in my forumotion forum with a mobile device (smartphone) with classic version (not mobile version) the last sent message appears in "New PM".
    So we first have to delete the last sent message.

    Is it possible that the last sent messagw won't appear by using mobile device?
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    Solved Re: PM: Last sent message appears

    Post by Ange Tuteur April 30th 2015, 9:57 am

    Hi @darki,

    Have you installed the following script ?
    https://help.forumotion.com/t132804-automatically-save-posts-in-progress

    If so, that's most likely the reason why the last sent PM is appearing in the textarea.
    avatar
    darki
    Forumember


    Posts : 254
    Reputation : 10
    Language : German, english

    Solved Re: PM: Last sent message appears

    Post by darki April 30th 2015, 10:15 am

    Yes, I have installed it.
    It is possible to remove the function that the last sent message appears, but the script still works?
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    Solved Re: PM: Last sent message appears

    Post by Ange Tuteur April 30th 2015, 10:21 am

    Try replacing it with this :
    Code:
    window.localStorage&&$(function(){
    $(function(){
    if($("#text_editor_textarea").length&&typeof $.sceditor!="undefined"){
    var a=$(document.post.mode).val(),
    d=$("#text_editor_textarea").sceditor("instance"),
    e,f,g=function(){
    localStorage.setItem(a,d.val());
    f=0},
    b=JSON.parse(localStorage.getItem("br-data"))||[],c;
    switch(a){
    case"editpost":return;
    case"post":return;
    case"reply":a+=$(document.post.t).val();
    break;
    case"newtopic":a+=$(document.post.f).val()
    }
    a=parseInt((my_getcookie("fa_"+location.hostname.replace(/\./g,"_")+"_data")||"0").replace(/.*s:6:"userid";(i:([0-9]+)|s:[0-9]+:"([0-9]+)");.*/,"$2$3"))+a;
    -1!=(c=$.inArray(a,b))&&b.splice(c,1);
    if(20<b.length){
    for(c=b.length-1;0<=c;c--)/^\s*$/.test(localStorage.getItem(b[c])||"")&&(localStorage.removeItem(b[c]),
    b.splice(c,1));
    20<b.length&&(localStorage.removeItem(b[0]),
    b.splice(0,1))}b.push(a);
    localStorage.setItem("br-data",JSON.stringify(b));
    $(document.post).submit(function(){
    localStorage.setItem("br-target",a)
    });
    !d.val()&&((e=localStorage.getItem(a))&&d.val(e));
    d.keyUp(function(){
    f||(f=setTimeout(g,3E3))
    })}})});
    window.localStorage&&(localStorage.getItem("br-target")&&function(){
    $("meta[http-equiv='refresh'][content]:first").length&&function(){
    var a=JSON.parse(localStorage.getItem("br-data")),
    b=localStorage.getItem("br-target"),c;
    if(-1!=(c=$.inArray(b,a)))a.splice(c,1),
    localStorage.setItem("br-data",JSON.stringify(a));
    localStorage.removeItem(b)}();
    localStorage.removeItem("br-target")}());
    avatar
    darki
    Forumember


    Posts : 254
    Reputation : 10
    Language : German, english

    Solved Re: PM: Last sent message appears

    Post by darki April 30th 2015, 11:25 am

    It seems to be working, thank you!!
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    Solved Re: PM: Last sent message appears

    Post by Ange Tuteur April 30th 2015, 7:30 pm

    You're welcome ^^

    Topic archived

    Have a nice day. )