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.

automatic post

View previous topic View next topic Go down

Solved automatic post

Post by DeathLess on July 6th 2017, 8:54 am

Hi!
Is possible to post an automatic post, when somebody create a new topic?
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by Justice™ on July 6th 2017, 9:56 am

Yes, it's possible. Forum link?
avatar
Justice™
Forumember

Posts : 514
Reputation : 117
Language : Romanian and English

http://board.realmsn.com

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 6th 2017, 11:49 am

Wolfuryo wrote:Yes, it's possible. Forum link?
http://www.minervasite.org
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by SLGray on July 6th 2017, 8:02 pm

Do you mean a message or a form to fill out?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.

avatar
SLGray
Administrator
Administrator

Male Posts : 40175
Reputation : 2714
Language : English
Location : United States

https://fmthemes.forumotion.com/

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 7th 2017, 6:53 am

SLGray wrote:Do you mean a message or a form to fill out?
A message.
For exemple, x create a new topic, then the first message will be an automatic message.
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by SLGray on July 7th 2017, 7:14 pm

For exemple, x create a new topic, then the first message will be an automatic message.

X message will be the first message. Did you mean first reply?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.

avatar
SLGray
Administrator
Administrator

Male Posts : 40175
Reputation : 2714
Language : English
Location : United States

https://fmthemes.forumotion.com/

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 7th 2017, 8:46 pm

SLGray wrote:For exemple, x create a new topic, then the first message will be an automatic message.

X message will be the first message. Did you mean first reply?
Oh, yes. Sorry.
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by SLGray on July 7th 2017, 9:04 pm

Are you using #phpBB3 ?


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.

avatar
SLGray
Administrator
Administrator

Male Posts : 40175
Reputation : 2714
Language : English
Location : United States

https://fmthemes.forumotion.com/

Back to top Go down

Solved Re: automatic post

Post by Justice™ on July 7th 2017, 9:16 pm

Hi,

So basically:I make a new topic, then a message(not mine) is automatically posted, right?
avatar
Justice™
Forumember

Posts : 514
Reputation : 117
Language : Romanian and English

http://board.realmsn.com

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 8th 2017, 8:30 am

SLGray wrote:Are you using #phpBB3 ?
phpBB3 with Forumactif Edge.
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 8th 2017, 8:32 am

Wolfuryo wrote:Hi,

So basically:I make a new topic, then a message(not mine) is automatically posted, right?
Yes.
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by Justice™ on July 8th 2017, 11:38 am

Hi,

Add the following javascript code with placement on topics:
Code:
window.atp = {};
atp.copyright = "Coded by Wolfuryo. Use at your own risk :D. Usage of this code without this notice will result in the destruction of your forum";
atp.config = {
    mess: "AUTOPOST",
    name: "BOT",
    avatar: "https://imgfast.net/users/3412/19/22/63/avatars/102172-85.jpg",
    fields: 1
};
atp.mo = function() {
    if (atp.config.name) {
        var nm = $("[href*='u']>span>strong").eq(0).text();
        atp.html = atp.html.replace(new RegExp(nm, "g"), atp.config.name);
    };
    if (atp.config.mess) {
        var ms = $("div.content>div").eq(0).html();
        atp.html = atp.html.replace(ms, atp.config.mess);
    };
    if (atp.config.avatar) {
        var sr = $(".user-avatar>a>img").eq(0).attr("src");
        atp.html = atp.html.replace(sr, atp.config.avatar);
    };
    if (atp.config.fields) {
        var fd = $(".field-info").first().html();
        var df = $(".contact-info").first().html();
        atp.html = atp.html.split(fd).join("").split(df).join("");
    };
    var ed = $("ul.profile-icons").eq(0).html();
    atp.html = atp.html.split(ed).join("");
};
atp.app = function() {
    $(".content-block.post").first().after(atp.html);
};
atp.init = function() {
    if (!/t\d+/.test(location.pathname)) return;
    atp.html = "<div class='content-block post row2 online'>" + $(".content-block.post").first().html() + "</div>";
    atp.mo();
    atp.app();
};
$(function() {
    atp.init();
})

What you can edit:
Code:
mess: "AUTOPOST",
->You can replace AUTOPOST with the message you want to posted. If you want the original message(the one posted by the creator of the topic), replace AUTOPOST with 0.
Code:
name: "BOT",
The name that appears as the poster. Replace "BOT" with 0 to show to topic author's username.
Code:
avatar: "https://imgfast.net/users/3412/19/22/63/avatars/102172-85.jpg",
->The avatar. Again, replace with 0 to show the author's avatar.
Code:
 fields: 1
1 means that the fileds(by fields I mean reputation, number of messages etc.) are removed. 0->The fields from the topic's author are shown.
avatar
Justice™
Forumember

Posts : 514
Reputation : 117
Language : Romanian and English

http://board.realmsn.com

Back to top Go down

Solved Re: automatic post

Post by DeathLess on July 8th 2017, 1:12 pm

Thanks!!
It's WORKING!
avatar
DeathLess
Forumember

Male Posts : 59
Reputation : 1
Language : ForuMotion Hungarian Translator
Location : At Your Girlfriend's House

http://www.minervasite.org/

Back to top Go down

Solved Re: automatic post

Post by SLGray on July 8th 2017, 8:13 pm

Problem solved & topic archived.
Please read our forum rules: ESF General Rules


When your topic has been solved, ensure you mark the topic solved.
Never post your email in public.

avatar
SLGray
Administrator
Administrator

Male Posts : 40175
Reputation : 2714
Language : English
Location : United States

https://fmthemes.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