-
AuthorPosts
-
bohemiadesign Friend
bohemiadesign
- Join date:
- March 2010
- Posts:
- 194
- Downloads:
- 26
- Uploads:
- 19
- Thanks:
- 16
- Thanked:
- 1 times in 1 posts
March 20, 2010 at 5:28 am #149664Hi,
Is it possible to change the background image to cover the whole title for the module and not only the first word?
Thanks,
Jonas
Anonymous ModeratorJA Developer
- Join date:
- September 2014
- Posts:
- 9914
- Downloads:
- 207
- Uploads:
- 152
- Thanks:
- 1789
- Thanked:
- 2008 times in 1700 posts
March 22, 2010 at 10:51 am #337222Hi sir
Please try to do with my way:
Open template.css file, add following code section to the end of file:
.first-word {
background: none !important;
}.first-word strong {
background: none !important;
}Hope it helps
bohemiadesign Friendbohemiadesign
- Join date:
- March 2010
- Posts:
- 194
- Downloads:
- 26
- Uploads:
- 19
- Thanks:
- 16
- Thanked:
- 1 times in 1 posts
March 22, 2010 at 11:03 am #337223Hi,
Thanks for getting back to me. I tried that code but it removes the background completely – the text is still there but the background image is gone. I am still working on the localhost hence the reason I can’t post a link.Jonas
Anonymous ModeratorJA Developer
- Join date:
- September 2014
- Posts:
- 9914
- Downloads:
- 207
- Uploads:
- 152
- Thanks:
- 1789
- Thanked:
- 2008 times in 1700 posts
March 23, 2010 at 4:35 am #337338Hi bohemiadesign
Please try:
1 . Open templates/ja_rasite/css/template.css file
2. add my code as this link: http://www.joomlart.com/forums/showpost.php?p=170688&postcount=2
3. find following code section:div.ja-moduletable h3 span strong.first-word, div.moduletable h3 span strong.first-word {
background: url(../images/title-brown.gif) no-repeat top left #57212a;
color: #fff;
display: inline;
margin: 0 5px 0 0;
padding: 3px 0 4px 10px;
}div.ja-moduletable h3 span strong.first-word strong, div.moduletable h3 span strong.first-word strong {
background: url(../images/title-brown.gif) no-repeat top right;
margin: 0;
padding: 3px 10px 4px 0;
}
and change to:
div.ja-moduletable h3 span strong.first-word, div.moduletable h3 span strong.first-word {
display: inline;
}
div.ja-moduletable h3 span strong.first-word strong, div.moduletable h3 span strong.first-word strong {
margin: 0;
}
4. find following code section:
/* All title style ---*/
.title-brown h3 span strong.first-word {
background: url(../images/title-brown.gif) no-repeat top left #57212a !important;
}.title-brown h3 span strong.first-word strong {
background: url(../images/title-brown.gif) no-repeat top right #57212a !important;
}.title-black h3 span strong.first-word {
background: url(../images/title-black.gif) no-repeat top left #000000 !important;
}.title-black h3 span strong.first-word strong {
background: url(../images/title-black.gif) no-repeat top right #000000 !important;
}.title-blue h3 span strong.first-word {
background: url(../images/title-blue.gif) no-repeat top left !important;
}.title-blue h3 span strong.first-word strong {
background: url(../images/title-blue.gif) no-repeat top right !important;
}.title-green h3 span strong.first-word {
background: url(../images/title-green.gif) no-repeat top left #6C830E !important;
}.title-green h3 span strong.first-word strong {
background: url(../images/title-green.gif) no-repeat top right #6C830E !important;
}.title-orange h3 span strong.first-word {
background: url(../images/title-orange.gif) no-repeat top left #9E6202 !important;
}.title-orange h3 span strong.first-word strong {
background: url(../images/title-orange.gif) no-repeat top right !important;
}and remove or comment it.
Please backup all files before make any changes.
bohemiadesign Friendbohemiadesign
- Join date:
- March 2010
- Posts:
- 194
- Downloads:
- 26
- Uploads:
- 19
- Thanks:
- 16
- Thanked:
- 1 times in 1 posts
March 23, 2010 at 10:11 am #337372Hi,
Thanks for getting back.
The fix posted removes the background image – what I was after is how to have the background image to “cover” both word in the title.
For example if the title is – Latest News – I want the background to be behind both word not only the first word.I think it has something to do with this code in the module.php file (ja_rasite/html) but unfourunatley I don’t know my way around javascript very well.
// Add span to module title
$title = $module->title;
$pos = strpos($title, ' ');
if ( $pos !== false ) { $title = "<strong class="first-word"><strong>" . substr($title, 0, $pos+1) . "</strong></strong>" . substr($title, $pos+1); }
else { $title = "<strong class="first-word"><strong>" . $title . "</strong></strong>"; }
?>Thanks
Jonas
-
AuthorPosts
This topic contains 5 replies, has 2 voices, and was last updated by bohemiadesign 14 years, 9 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum