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.

How can I change the background of Stickies, Announcements, Global Announcements?

Page 1 of 2 1, 2  Next

View previous topic View next topic Go down

In progress How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Sun 9 Feb 2014 - 16:06

Hi all,
How can I change the background with an image or a background color of stickies, announcements and global announcements? My forum version is phpbb2.

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Chromo on Sun 9 Feb 2014 - 23:54

Add this to your javascript
Code:
$(document).ready(function() {
$('strong:contains("Sticky")').each(function(){
$(this).css({ "background-color": "blue"});
});
});

$(document).ready(function() {
$('strong:contains("Announcement")').each(function(){
$(this).css({ 'background-color': 'red'});
});
});

$(document).ready(function() {
$('strong:contains("Global announcement")').each(function(){
$(this).css({ 'background-color': 'green'});
});
});

Edit the part
'background-color': 'blue'
'background-color': 'red'

'background-color': 'green'


Don't delete " ' " on both side
avatar
Chromo
Forumember

Male Posts : 122
Reputation : 19
Language : said the Captain

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Mon 10 Feb 2014 - 1:18

xKillerZone31 wrote:Add this to your javascript
Code:
$(document).ready(function() {
$('strong:contains("Sticky")').each(function(){
$(this).css({ "background-color": "blue"});
});
});

$(document).ready(function() {
$('strong:contains("Announcement")').each(function(){
$(this).css({ 'background-color': 'red'});
});
});

$(document).ready(function() {
$('strong:contains("Global announcement")').each(function(){
$(this).css({ 'background-color': 'green'});
});
});

Edit the part
'background-color': 'blue'
'background-color': 'red'

'background-color': 'green'


Don't delete " ' " on both side

Its not working I have added the following code with translated text in Greek language as I have change the text in my control panel to be the same with javascript and I ticked the box In sub-forums.
Code:

$(document).ready(function() {
    $('strong:contains("Καρφιτσωμένο Θέμα")').each(function(){
    $(this).css({ 'background-color': 'blue'});
    });
    });

    $(document).ready(function() {
    $('strong:contains("Ανακοίνωση")').each(function(){
    $(this).css({ 'background-color': 'red'});
    });
    });

    $(document).ready(function() {
    $('strong:contains("Σημαντική Ανακοίνωση")').each(function(){
    $(this).css({ 'background-color': 'green'});
    });
    });
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Paulostge on Mon 10 Feb 2014 - 2:01

Code:
$(document).ready(function() {
$('strong:contains("Υπόμνημα:")').each(function(){
$(this).css({ 'background-color': 'red'});
});
});

$(document).ready(function() {
$('strong:contains("Ανακοίνωση:")').each(function(){
$(this).css({ 'background-color': 'green'});
});
});

$(document).ready(function() {
$('strong:contains("Global announcement")').each(function(){
$(this).css({ 'background-color': 'orange'});
});
});

avatar
Paulostge
Forumember

Male Posts : 99
Reputation : 17
Language : Greek
Location : Greece

http://www.thegreeksenergy.com

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Mon 10 Feb 2014 - 2:25

Its still not working
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Paulostge on Mon 10 Feb 2014 - 2:33

I have picture above and it works because normally try, you see for odd or wrong javascripts

control - shift - j

avatar
Paulostge
Forumember

Male Posts : 99
Reputation : 17
Language : Greek
Location : Greece

http://www.thegreeksenergy.com

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Paulostge on Mon 10 Feb 2014 - 2:49

Will need to delete them

avatar
Paulostge
Forumember

Male Posts : 99
Reputation : 17
Language : Greek
Location : Greece

http://www.thegreeksenergy.com

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Mati on Mon 10 Feb 2014 - 14:24

There may be some other javascript that can cause the problem.

Can you PM me details of a test account which has admin access? I would like to check.
avatar
Mati
Active Poster

Posts : 1900
Reputation : 288
Language : || HTML || CSS || jQuery ||
Location : At the Gym

http://forumdirectory.forumotion.net/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Wed 12 Feb 2014 - 0:25

@Paulostge wrote:Will need to delete them

Hi,
At the first phase I have removed the Greek words and left the fields empty to test if it works and I was substitute the Greek words with english words in the javascript but it isn't working by this way. At the second phase I was filled the fields with the English words Sticky, Announcement, and Global Announcement texts which I was replace them at javascript too. The problem still remains.

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Paulostge on Wed 12 Feb 2014 - 23:54

Dark-Avenger wrote:
@Paulostge wrote:Will need to delete them

Hi,
At the first phase I have removed the Greek words and left the fields empty to test if it works and I was substitute the Greek words with english words in the javascript but it isn't working by this way. At the second phase I was filled the fields with the English words Sticky, Announcement, and Global Announcement texts which I was replace them at javascript too. The problem still remains.

Best Regards,
Dark-Avenger

As I showed in the picture above in a test page, the code worked fine, also the words are not in English but in GREEK
avatar
Paulostge
Forumember

Male Posts : 99
Reputation : 17
Language : Greek
Location : Greece

http://www.thegreeksenergy.com

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Thu 13 Feb 2014 - 0:13

@Paulostge wrote:
Dark-Avenger wrote:
@Paulostge wrote:Will need to delete them

Hi,
At the first phase I have removed the Greek words and left the fields empty to test if it works and I was substitute the Greek words with english words in the javascript but it isn't working by this way. At the second phase I was filled the fields with the English words Sticky, Announcement, and Global Announcement texts which I was replace them at javascript too. The problem still remains.

Best Regards,
Dark-Avenger

As I showed in the picture above in a test page, the code worked fine, also the words are not in English but in GREEK
I have tried with Greek and English words like your example, I have removed the texts in the boxes and it still not working. Probably the reason is the forum version or needs to change something in the javascript. Furthermore I was clean my forum cookies and my browser's cache. Is it need a part of CSS Code additionally?

Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Paulostge on Thu 13 Feb 2014 - 0:35

It dont need anything extra to try something else to see if any blame javascript, disable all javascript and then put his code in topics_list_box

Code:

<script>
$(document).ready(function() {
$('strong:contains("Υπόμνημα:")').each(function(){
$(this).css({ 'background-color': 'red'});
});
});

$(document).ready(function() {
$('strong:contains("Ανακοίνωση:")').each(function(){
$(this).css({ 'background-color': 'green'});
});
});
</script>
avatar
Paulostge
Forumember

Male Posts : 99
Reputation : 17
Language : Greek
Location : Greece

http://www.thegreeksenergy.com

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Mon 17 Feb 2014 - 2:27

@Paulostge wrote:It dont need anything extra to try something else to see if any blame javascript, disable all javascript and then put his code in topics_list_box

Code:

<script>
$(document).ready(function() {
$('strong:contains("Υπόμνημα:")').each(function(){
$(this).css({ 'background-color': 'red'});
});
});

$(document).ready(function() {
$('strong:contains("Ανακοίνωση:")').each(function(){
$(this).css({ 'background-color': 'green'});
});
});
</script>
Its stills not working
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Fri 21 Feb 2014 - 16:11

bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Sun 23 Feb 2014 - 10:07

Today I was tried another similar script
Code:

$(document).ready(function(){$('strong:contains("Σημαντική Ανακοίνωση:")').each(function(){$(this).css({'color':'#fff','background':'url("http://www.dodaj.rs/f/14/Ua/4moBrDA0/highlight.png") repeat-x 0 -1px #2E9AFE','border-radius':'3px 3px 3px 3px','display':'inline-block','font-size':'9px','font-weight':'bold','height':'16px','line-height':'16px','padding':'0 5p','text-shadow':'0 -1px 0 rgba(0, 0, 0, 0.2)','text-transform':'uppercase','vertical-align':'middle',})})});$(document).ready(function(){$('strong:contains("Ανακοίνωση:")').each(function(){$(this).css({'color':'#fff','background':'url("http://i43.servimg.com/u/f43/14/73/12/96/stk10.png") repeat-x 0 -1px #FF4000','border-radius':'3px 3px 3px 3px','display':'inline-block','font-size':'9px','font-weight':'bold','height':'16px','line-height':'16px','padding':'0 5p','text-shadow':'0 -1px 0 rgba(0, 0, 0, 0.2)','text-transform':'uppercase','vertical-align':'middle',})})});$(document).ready(function(){$('.tcl strong:contains("Καρφιτσωμένο Θέμα:")').each(function(){$(this).css({'color':'#fff','background':'url("http://i43.servimg.com/u/f43/14/73/12/96/stk10.png") repeat-x 0 -1px #7BA60D','border-radius':'3px 3px 3px 3px','display':'inline-block','font-size':'9px','font-weight':'bold','height':'16px','line-height':'16px','padding':'0 5p','text-shadow':'0 -1px 0 rgba(0, 0, 0, 0.2)','text-transform':'uppercase','vertical-align':'middle',})})});
but and this script doesnt change anything for the other forum version these scripts using a selector like .tcl or dd.tem for phpbb2 thereisn't a selector?
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Pizza Boi on Sun 23 Feb 2014 - 16:44

Hi Very Happy

Try dd.dterm as the ID.

Regards,
Pizza Boi
avatar
Pizza Boi
Hyperactive

Male Posts : 2016
Reputation : 160
Language : French
Location : Pizza Hut!

http://redlustempire.forumtl.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Jophy on Mon 24 Feb 2014 - 14:00

Hello,

Have you tried looking into the French support forum for a tutorial? Try this:
http://forum.forumactif.com/t348011-coloriser-les-cases-des-post-it-et-des-annonces
avatar
Jophy
ForumGuru

Male Posts : 17924
Reputation : 835
Language : English
Location : Somewhere

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Tue 25 Feb 2014 - 0:02

@Jophy wrote:Hello,

Have you tried looking into the French support forum for a tutorial? Try this:
http://forum.forumactif.com/t348011-coloriser-les-cases-des-post-it-et-des-annonces
Hi Jophy,
I have customized this script like this

Javascript:
Code:

$(function() {
$('img[src="http://i57.servimg.com/u/f57/18/10/12/74/greenp10.png"]').closest('tr').addClass('sticky');
$('img[src="http://i72.servimg.com/u/f72/18/10/12/74/warn10.png"]').closest('tr').addClass('announcement');
$('img[src="http://i72.servimg.com/u/f72/18/10/12/74/announ10.png"]').closest('tr').addClass('globalannouncement');
});

and I was add this in the CSS:
Code:

tr.sticky td {background-color:#008000!important;}
tr.announcement td {background-color:#FFA500!important;}
tr.globalannouncement td {background-color:#FF0000!important;}


but its not working.This script change this http://prntscr.com/2vl97e

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Thu 27 Feb 2014 - 14:25

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Sat 1 Mar 2014 - 23:15

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Tue 4 Mar 2014 - 11:40

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by JScript on Tue 4 Mar 2014 - 12:01

@Dark-Avenger

Hello!

Which forum you are testing the codes?
Please let us know the address of your forum I assure you that you will have help faster and avoiding unnecessary posts!

JS
avatar
JScript
Forumember

Male Posts : 741
Reputation : 172
Language : PT-BR, EN
Location : Brazil

http://jscript.forumeiros.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Tue 4 Mar 2014 - 12:39

@JScript wrote:@Dark-Avenger

Hello!

Which forum you are testing the codes?
Please let us know the address of your forum I assure you that you will have help faster and avoiding unnecessary posts!

JS

Hello JScript,
I am testing it in my forum
Spoiler:
I havent a testing forum.

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by JScript on Tue 4 Mar 2014 - 12:55

@Dark-Avenger

Thanks for the info, use the following CSS:
Code:

.index-row div.topictitle {
 background-color: red;
}
.index-row div.topictitle h2, .index-row div.topictitle > span {
 background-image: url("http://i57.servimg.com/u/f57/18/21/41/30/vaoolo10.png");
}
Change red for the color you want!

Result:


So long,

JS
avatar
JScript
Forumember

Male Posts : 741
Reputation : 172
Language : PT-BR, EN
Location : Brazil

http://jscript.forumeiros.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Tue 4 Mar 2014 - 13:18

Its working, but stickies, announcements, global announcements have the same color, can I have different color for each one?
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by JScript on Tue 4 Mar 2014 - 14:46

Yes, of course!!!

See this imagem:


Put in [Define another name for Stickies:]

Code:
<span class="stickies">Stickies:</span>


Put in [Define another name for Announcements:]

Code:
<span class="announcements">Announcements:</span>


Put in [Customize a global announcemente name:]

Code:
<span class="global">Global announcements:</span>


Translate the names Stickies:, Announcements: and Global announcements: into your language!

Now, add the CSS below:

Code:

.stickies, .announcements, .global {
 border-radius: 2px 2px 2px 2px;
 padding-left: 4px;
 padding-right: 4px;
}
.global {
 background-color: red;
}
.announcements {
 background-color: green;
}
.stickies {
 background-color: blue;
}


Result:


Note: This is just an example ok?



Edit:
Jeez, I just know that this is not possible because the field size on the control panel is too small to add the HTML ...

But reading the whole thread I came across the following message: http://help.forumotion.com/t130521-how-can-i-change-the-background-of-stickies-announcements-global-announcements#874744
In which I did tests and it worked perfectly!

So long,

JS


Last edited by JScript on Tue 4 Mar 2014 - 14:55; edited 2 times in total (Reason for editing : Jeez...)
avatar
JScript
Forumember

Male Posts : 741
Reputation : 172
Language : PT-BR, EN
Location : Brazil

http://jscript.forumeiros.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Tue 4 Mar 2014 - 19:26

@JScript wrote:Yes, of course!!!

See this imagem:


Put in [Define another name for Stickies:]

Code:
<span class="stickies">Stickies:</span>


Put in [Define another name for Announcements:]

Code:
<span class="announcements">Announcements:</span>


Put in [Customize a global announcemente name:]

Code:
<span class="global">Global announcements:</span>


Translate the names Stickies:, Announcements: and Global announcements: into your language!

Now, add the CSS below:

Code:

.stickies, .announcements, .global {
 border-radius: 2px 2px 2px 2px;
 padding-left: 4px;
 padding-right: 4px;
}
.global {
 background-color: red;
}
.announcements {
 background-color: green;
}
.stickies {
 background-color: blue;
}


Result:


Note: This is just an example ok?



Edit:
Jeez, I just know that this is not possible because the field size on the control panel is too small to add the HTML ...

But reading the whole thread I came across the following message: http://help.forumotion.com/t130521-how-can-i-change-the-background-of-stickies-announcements-global-announcements#874744
In which I did tests and it worked perfectly!

So long,

JS
Hi JS,
First of all I cant declare them as classes because the code it doesnt fit in the boxes, after that I have try this example again without success(change tha variable into Greek and English languages in JS and CSS). Furthermore I cant find these variables to modify them. Do you know in which template should be found them?

Best Regards,
Dark-Avenger
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Fri 7 Mar 2014 - 2:55

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Sun 9 Mar 2014 - 0:11

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

In progress Re: How can I change the background of Stickies, Announcements, Global Announcements?

Post by Van-Helsing on Mon 10 Mar 2014 - 2:28

Bump
avatar
Van-Helsing
Hyperactive

Male Posts : 2380
Reputation : 110
Language : English, Greek

http://helpgr.forumgreek.com/

Back to top Go down

Page 1 of 2 1, 2  Next

View previous topic View next topic Back to top


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