You are not connected. Please login or register

Topic thanked message problem

Page 1 of 2 Go to page : 1, 2  Next

Anonymous

Guest

Guest

PostGuest Wed Feb 23, 2022 2:55 pm

I added this java code
Code:
$(function() {
  var thanked = $('#main-content > .post[style*="background-color"]')[0];

  if (thanked) {
    thanked.className += ' thanked-post';
    thanked.style.backgroundColor = '';

    thanked.insertAdjacentHTML(
      'beforeend',
      '<div class="thanked-message"><i class="fa fa-thumbs-up"></i> The topic starter has thanked {USERNAME} !</div>'
      .replace('{USERNAME}', $(thanked).find('p.author a').text())
    );

    $('head').append('<style type="text/css">'+
                     '.thanked-post .thanked-message { color:#FFF; font-size:12px; background:#88cc55; border-radius:2px; border-bottom:1px solid #77BB44; padding:0px 10px; margin-bottom: -6px; margin-left: -5px; margin-right: -5px; height: 30px; line-height: 31px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }'+
      '.thanked-message .fa-thumbs-up { font-size:16px; margin-right:5px; vertical-align:-2px; }'+

      '@media (min-width:0px) and (max-width:768px) {'+
        '.thanked-post { padding-bottom:116px; }'+
        '.thanked-post .thanked-message { position:absolute; bottom:0; left:0; right:0; }'+
        '.thanked-post .postbody .profile-icons { bottom:44px; }'+
      '}'+
    '</style>');
  }
});
It is working fine in phpbb3 but not working in this forum. Could you edit it @Admin?


Last edited by The sea on Sun Feb 27, 2022 3:31 pm; edited 1 time in total
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Wed Feb 23, 2022 3:32 pm

Too complicated for me. Gotta ask some Forumotion experts, at FMCodes for instance.
Anonymous

Guest

Guest

PostGuest Wed Feb 23, 2022 4:44 pm

You got any solution? This script is written for phpbb3? I am not sure but it is 100% correct code
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Wed Feb 23, 2022 5:06 pm

As I already said, I don't know.

But phpBB 3 and PunBB is not the same, so of course code made for phpBB will not work for PunBB
Anonymous

Guest

Guest

PostGuest Wed Feb 23, 2022 5:06 pm

Topic starter will give result like this one below:
Topic thanked message problem Screen11
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Wed Feb 23, 2022 5:06 pm

I understand what it is. But as I said: I have no idea
Anonymous

Guest

Guest

PostGuest Wed Feb 23, 2022 5:09 pm

I have idea. I have a demo version of forumotion. It is punbb forum. I can give you password of it. You can learn more about it....
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Wed Feb 23, 2022 5:11 pm

The sea wrote:I have idea. I have a demo version of forumotion. It is punbb forum.  I can give you password of it. You can learn more about it....

What?

I know that:
1) the code works on phpBB
2) the code does not work on PunBB

I don't know:
1) how to make it work for PunBB

phpBB and PunBB are two entirely different things, and stuff that works for phpBB does not necessarily work for PunBB
Anonymous

Guest

Guest

PostGuest Wed Feb 23, 2022 5:28 pm

Let me send you punbb code for it
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Thu Feb 24, 2022 4:08 pm

Hello,

i will fix this also, but i need to look carefully for it Razz
Anonymous

Guest

Guest

PostGuest Thu Feb 24, 2022 4:20 pm

Ok, waiting for it dude Very Happy
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:13 am

Nearly all problems are solved. I am wanting you solve this issue too that i am feeling to press thanks button on your post. Haha😁
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 1:19 am

will do that right now, looks like forumotion was down... and i was not accesibile at all
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:25 am

Yeah same happens to me. Let's move for it...
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 1:31 am

it was a topic from forumotion, with a modification for the system with likes/dislikes, i cant find it anymore... idk why, or im too blind to see it...
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:33 am

No, this script shows the result " The topic starter has thanked the admin or username! "
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:35 am

The sea wrote:I added this java code
Code:
$(function() {
  var thanked = $('#main-content > .post[style*="background-color"]')[0];

  if (thanked) {
    thanked.className += ' thanked-post';
    thanked.style.backgroundColor = '';

    thanked.insertAdjacentHTML(
      'beforeend',
      '<div class="thanked-message"><i class="fa fa-thumbs-up"></i> The topic starter has thanked {USERNAME} !</div>'
      .replace('{USERNAME}', $(thanked).find('p.author a').text())
    );

    $('head').append('<style type="text/css">'+
                     '.thanked-post .thanked-message { color:#FFF; font-size:12px; background:#88cc55; border-radius:2px; border-bottom:1px solid #77BB44; padding:0px 10px; margin-bottom: -6px; margin-left: -5px; margin-right: -5px; height: 30px; line-height: 31px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }'+
      '.thanked-message .fa-thumbs-up { font-size:16px; margin-right:5px; vertical-align:-2px; }'+

      '@media (min-width:0px) and (max-width:768px) {'+
        '.thanked-post { padding-bottom:116px; }'+
        '.thanked-post .thanked-message { position:absolute; bottom:0; left:0; right:0; }'+
        '.thanked-post .postbody .profile-icons { bottom:44px; }'+
      '}'+
    '</style>');
  }
});


It is working fine in phpbb3 but not working in this forum. Could you edit it @Admin?

This code mainly written by Ange Tutuer for phpbb3 forum. Need to convert it to punbb
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 1:44 am

yes i know, about that code... but we need to make some modification(s), in order for it to work...
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:45 am

Yes indeed.
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 1:52 am

okay, its added... but somehow is above up, and not down LOL
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 1:55 am

Intested and clicked on thanka button but still i don't see thanks message.
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 1:59 am

i have bad news for you, im not a javascript coder, and i dont know how to make this working for punbb...

i can help you with anything else, if you want Very Happy
Anonymous

Guest

Guest

PostGuest Fri Feb 25, 2022 2:02 am

Ok, do what you want. I respect your new inventions
Administrator

Administrator

Administrator
Administrator
Posts : 128
Points : 145
Reputation : 14
Join date : 2022-02-13
https://movie.goodforum.net

PostAdministrator Fri Feb 25, 2022 2:02 am

Anonymous

Guest

Guest

PostGuest Tue Mar 01, 2022 6:22 am

Very Happy

Sponsored content

PostSponsored content

Go to page : 1, 2  Next

View previous topic View next topic Back to top

Create an account or log in to leave a reply

You need to be a member in order to leave a reply.

Create an account

Join our community by creating a new account. It's easy!


Create a new account

Log in

Already have an account? No problem, log in here.


Log in

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