Sorry if this is an old question, I have searched the forum for an answer

Sorry if this is an old question, I have searched the forum for an answer

Mike Williams -
回帖数:28

The clickable link and text in the message block is very small on the front page. Is there a way I can enlarge it?

Many thanks in advance

回复Mike Williams

Re: Is there anyone that can help with the above?

Mike Williams -

Is there anyone that could help me with the above? I'm a bit stuck at the moment and cant make the message block available because the text is too small for people to see?

Many thanks in advance

回复Mike Williams

Re: message block styling

Helen Foster -
Core developers的头像 Documentation writers的头像 Moodle HQ的头像 Particularly helpful Moodlers的头像 Plugin developers的头像 Testers的头像 Translators的头像
Hi Mike,

What theme are you using? If it's a custom theme, then perhaps you can post a screenshot illustrating the problem.

I'm going to give this posting a more meaningful subject line and move it to the themes forum where hopefully someone will be able to help.
回复Helen Foster

Re: message block styling

Mike Williams -
Many thanks 微笑 I did'nt know it was a theme problem...but this is the problem that I have on our live site, the message block text is very small and I would like to change the title of the block itself also..many thanks...Mike

message block text

回复Mike Williams

Re: message block styling

Mauno Korpelainen -

OK - change the previous code to

.block_messages .footer a, .block_messages .message a, .block_messages .user a {
font-size:1.5em;
line-height:2em;
}

and that "Messages" is bigger too

You could also use px or pt or % values...

回复Mauno Korpelainen

Re: message block styling

Mike Williams -
Hi Mauno I have pasted the script and I still have the problem, sorry if its something I'm doing or not doing...this side of things is new to me....many thanks indeed.

pic

problem
回复Mike Williams

Re: message block styling

Mauno Korpelainen -
If nothing happens your css files have probably some tags AFTER these tags that override the tags you just pasted. Try to paste the code to the end of css file (last css file in theme css sheets array in config.php)
回复Mauno Korpelainen

Re: message block styling

Mike Williams -
Sorry.... are you saying paste the code at the bottom of the file called config.php?
回复Mike Williams

Re: message block styling

Mauno Korpelainen -

No - at the bottom of styles_fonts.css etc - if you open your theme folder, for example theme/Clouds/config.php you should find a row like

$THEME->sheets = array('styles_layout', 'styles_fonts', 'styles_color');

and you could paste the css to styles_fonts.css or styles_colors.css found from the same folder. If standard sheets is true and no custom sheets are defined paste the code to standard theme css files... 
回复Mike Williams

Re: message block styling

Mauno Korpelainen -

Mike,

one more thing - if you need to change size of text "No messages waiting" the css is

.block_messages .info, .block_messages .footer a, .block_messages .message a, .block_messages .user a {
font-size:1.5em;
line-height:2em;
}

Instead of those values you could use for example font-size:12px; and line-height:16px; (I did not know which theme you have - standard theme has em values but several themes use pixels)

Check also that you have pasted css to correct theme (your current theme) css file. By the way...what version of moodle you have? (tested this with moodle 1.8 myself)

回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

Mike,

add for example the following css to the end of the last css file in your theme config.php $THEME->sheets = array(...):

.sideblock .message a {
font-size:1.5em;
line-height:2em;
}

if you want to change font size of the name too use

.sideblock .message a, .sideblock .user a {
font-size:1.5em;
line-height:2em;
}

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

Or even better

.block_messages .message a, .block_messages .user a {
font-size:1.5em;
line-height:2em;
}

Then font size of other such blocks that have class "user" (at least Online users block) is not changed...

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Many Many thanks, I will give this a go....I have managed to get an image of the problem and put it on my test site

small message text
回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Hi Mauno, many thanks for your time and help

I copied and pasted as you suggested, but I still have the same problem as the image below, is there any more I can do?:

.block_messages .message a, .block_messages .user a {
font-size:1.5em;
line-height:2em;
}

problem piv
回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -
After change to css press F5 (note that previous change to footer tag)
回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Hi Mauno...I really appreciate you helping like this...I did ctrl f5 on both accounts to refresh the browser but there is still no change 伤心

Mike
回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

May I check your site somewhere in  www ? All I need is to see the source code (css files)

Edit: I'm sure that this code works in moodle 1.8 with standard theme css but you have not told either your version of moodle or theme so I can't test it - sometimes pages may stay in cache for some time.

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Sorry.... I am using 1.8.2.... and sadly I can't give you access to the css files on our server due to security outside of my control, what If I copy the file to a test site that I use for you to open and look at?

again many thanks
回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

Well there really should not be any secrets in css files...if you look at source code of moodle.org you find after <head> ...

<link rel="stylesheet" type="text/css" href="http://moodle.org/theme/standard/styles.php?lang=en_utf8" />
<link rel="stylesheet" type="text/css" href="http://moodle.org/theme/moodleorange/styles.php?lang=en_utf8" />

and so on. Moodle reads first css from standard theme, then from custom theme, then from css for ie7 or ie6 and if you have not made any changes to core code the latter tags always override the former tags. It's the same in css files. Css at the bottom overrides css at the top.

On the other hand if you read source code of your site you should see some "classes" before "Messages" etc - those classes are used in css to give certain properties for the following html tags. With Firefox Web Developer plugin you may view css for different tags yourself too wink

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Thank you so much for your time and you have probably realised by now I'm out of my depth with this 伤心 is this where I post the script? underneath theme->sheets = array ('fw_layout etc etcpic
回复Mike Williams

Re: Is there anyone that can help with the above?

chris dennison -
Hello - reading this post eminded me about my problems when I first installed a new theme.

Use the Firefox browser and download a plugin called greasemonkey. I can't remeer all the details but this allows you to see which element of css i controlling a particular element of the page.

When set up you shift+click on a field and it displays element information then you can have the option to edit the css temporarily

Have a look around for more information - but this saved my bacon 微笑
回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

Mike,

if this is your theme config.php - open file fw_fonts.css from the same folder, paste the code I gave you after all other tags in that file , save and move to your server to correct folder.

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Hi Mauno

Found fw_fonts.css pasted the code but still no joy 伤心 not sure what "move to your server to correct folder" means?...sorry
pic
回复Mike Williams

Re: Is there anyone that can help with the above?

Mauno Korpelainen -

To that folder where your theme (on server) is...

yourmoodlesite/theme/yourtheme/fw_fonts.css

One note about greasemonkey - I have not used it and vulnerabilities from the past may be fixed but read this before you start running scripts through greasemonkey

 http://tipsosaurus.com/security-tips/security-threats-of-using-greasemonkey

回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Mike Williams -
Hi Mauno....I just wanted to say thank you very much for all your help, but I think I'm going to give up 伤心 I cant seem to fix this issue due to my own lack of knowledge at this moment in time

Many thanks once again
回复Mauno Korpelainen

Re: Is there anyone that can help with the above?

Frank Ralf -
JFTR

Greasemonkey's security holes have been long since closed:

"Avoid Common Pitfalls in Greasemonkey - How the History of Greasemonkey Security Affects You Now"
by Mark Pilgrim, author of Greasemonkey Hacks
http://www.oreillynet.com/pub/a/network/2005/11/01/avoid-common-greasemonkey-pitfalls.html
(for more information on Greasemonkey see http://diveintogreasemonkey.org/)

And I suppose the above mentioned Firefox plugin is meant to be Firebug.

And CSS FAQ and Themes FAQ are always good starting points for learning more about CSS and theming.

Cheers,
Frank
回复Mike Williams

Re: Sorry if this is an old question, I have searched the forum for an answer

ian lake -

Is this theme related to the flex rooms theme?

ian

回复ian lake

Re: Sorry if this is an old question, I have searched the forum for an answer

Mike Williams -
Sorry Ian I have no idea, I have taken over the role of admin for this site and I am only a few months into it, so still finding my way.