News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Add pictures next to the board

Started by bharat, January 29, 2018, 05:43:05 AM

Previous topic - Next topic

bharat

How can I add an additional picture next to the board, something like the one in the attachment.

Steve

DO NOT pm me for support!

bharat

Is it the only way or maybe there is some mod? As I understood I need to add images first and then add code with URL?


bharat

I tried these mods but I would like something next to the main picture, the same as I showed earlier.

Aleksi "Lex" Kilpinen

I think this would still be a good starting point.
Quote from: Steve on January 29, 2018, 06:28:10 AM
Something like this? https://www.simplemachines.org/community/index.php?topic=539000.msg3830565#msg3830565
Other than that, you can try to search the mod site or this could be moved to Coding discussion.
Slava
Ukraini!


"Before you allow people access to your forum, especially in an administrative position, you must be aware that that person can seriously damage your forum. Therefore, you should only allow people that you trust, implicitly, to have such access." -Douglas

How you can help SMF

bharat

I checked this link and as I understood the image will appear next to the name of the board or next to the description. I want to keep the same images but add an additional ones next to it.

Kindred

then either use CSS or get someone to custom code it for you.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

bharat

I need a code of CSS so that the images appear in the right place.

Kindred

you need to start learning basic html and css.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

bharat

#10
I just tried to add this code to index.css but no picture appeared on the forum:


#board_82 > .info > a::before {
   content: "";
   height: 34px;
   width: 35px;
   position: absolute;
   margin-left: 5px;
   background: url(http://www.forum.bharatconnect.net/Themes/default/images/li4.png) no-repeat;
}

Gwenwyfar

Are you sure you are using the right board ID? That should work fine.

Better to change it to this though:
#board_{ID} > .info > a::before {
   content: "";
   height: 34px;
   width: 35px;
   display: inline-block;
   margin-right: 5px;
   background: url(http://www.forum.bharatconnect.net/Themes/default/images/li4.png) no-repeat;
}
"It is impossible to communicate with one that does not wish to communicate"

bharat

Yes, I open the board and checked the number. Do I need to add this code to index.css, right? I add it in the end but nothing happened. I have one picture at the moment and wanted to add one small one like on the picture I posted bellow.

Gwenwyfar

This code works on the main boards, it doesn't work on child board descriptions on board index. For example your board "7". Other than that, just make sure you're clearing your cache after you add your changes.
"It is impossible to communicate with one that does not wish to communicate"

bharat

Yes, I was trying on the main boards, not on the child one. Still I didn't see any changes, will try again with this code.

Gwenwyfar

You may have to clear your cache after any css changes.
"It is impossible to communicate with one that does not wish to communicate"

bharat

I cleared the cache but nothing happened.

bharat

I have picture like in the attachment now and would like to add a small one next to the main image.

Gwenwyfar

"It is impossible to communicate with one that does not wish to communicate"

bharat

The same like on the code I posted earlier?

Advertisement: