Author Topic: CSS problem  (Read 893 times)

0 Members and 1 Guest are viewing this topic.

Offline Mido

CSS problem
« on: 24. July 2010, 15:36:53 »
Hi,
Today I have set Simple Featured Entries Module to my homepage ( http://nasigurno.com )
I modified the template css to get a second look smplefeautired module. Although my knowledge of css modestly I managed to get what I wanted. I have only one problem. The image on the right side is lowered below the title. I've tried various ways to raise, but I failed.
Here ( http://nasigurno.com/slike/ns.jpg ) you can see exactly what it is and the right picture as they would like to look.
Css  that I wrote looks like this:

div.mod_sobi2simplefeatured  div.entry {
  background: #F6F6F6;
  border: 2px solid #DDDDDD;
  padding-left:15px;
  padding-right:15px;
  margin: 0 0 5px;
  float:right;
  position:relative;
  left:-2%;
  width:90%;
  height:140px;
}
div.mod_sobi2simplefeatured div.title {
  font-size: 17px;
  font-weight: bold;
  padding-top:5px;
}
div.mod_sobi2simplefeatured div.image img {
  height: 100px;
  padding-top:-33px;
  float:right;
  }

Thanks
Country: Bosnia and Herzegovina Bosnia and Herzegovina |  OS: Windows 7/Server 2008 R2 Windows 7/Server 2008 R2 |  Browser: Firefox 3.6.7 Firefox 3.6.7 | View Profile


Offline aboututila

Re: CSS problem
« Reply #1 on: 24. July 2010, 19:42:58 »
Because of the way your Site Template is designed, and to get something that looks like your ns.jpg illustration,
I would suggest trying;
div.mod_sobi2simplefeatured  div.entry {
  background: #F6F6F6;
  border: 2px solid #DDDDDD;
  padding: 2px 15px;
  margin: 2px;
  float:left;
  width:255px;
  height:110px;
}
div.mod_sobi2simplefeatured div.title {
  font-size: 17px;
  font-weight: bold;
  padding-top:5px;
}
div.mod_sobi2simplefeatured div.image img {
  height: 100px;
  margin-top: -23px;
  float:right;
}

Layout works OK in Firefox, you may need to check it in Internet Explorer

Your other option is to change the sequence of how mod_sobi2simplefeatured outputs the HTML elements (output the image before the other elements and then float:right the image) by modifying {MyJoomlaInstallation}/modules/mod_sobi2simplefeatured/tmpl/default.php - See Module Template

Regards - Mark
Country: Honduras Honduras |  OS: Windows XP Windows XP |  Browser: Firefox 3.6.7 Firefox 3.6.7 | View Profile

Offline Mido

Re: CSS problem
« Reply #2 on: 24. July 2010, 20:15:17 »
I just change this:

  float:right;
  position:relative;
  left:-2%;
  width:90%;
  height:110px;

and is OK now.
Thanks a lot,
Midhat
Country: Bosnia and Herzegovina Bosnia and Herzegovina |  OS: Windows 7/Server 2008 R2 Windows 7/Server 2008 R2 |  Browser: Firefox 3.6.6 Firefox 3.6.6 | View Profile

Offline aboututila

Re: CSS problem
« Reply #3 on: 24. July 2010, 20:57:50 »
I am glad you found a solution.
I am sorry, but in your ns.jpg illustration you showed two Entries side-by-side, and I thought this is what you wanted, hence my code suggestion.

Regards - Mark
Country: Honduras Honduras |  OS: Windows XP Windows XP |  Browser: Firefox 3.6.7 Firefox 3.6.7 | View Profile

Offline Mido

Re: CSS problem
« Reply #4 on: 24. July 2010, 21:15:19 »
That was what I had (left) and what I want Right)  ;)

Thanks again
Country: Bosnia and Herzegovina Bosnia and Herzegovina |  OS: Windows 7/Server 2008 R2 Windows 7/Server 2008 R2 |  Browser: Firefox 3.6.6 Firefox 3.6.6 | View Profile

Tags: