Advertisement:

Author Topic: css styles  (Read 1544 times)

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
css styles
« on: May 19, 2020, 05:09:02 PM »
Hello,

I just want to insert background-image and I opened this file, but whole style is written in a single line.
I am using SublimeText3 and how can I solve this issue?

Thanks.

Offline Shambles

  • SMF Hero
  • ******
  • Posts: 5,469
  • Gender: Male
    • i30 Owners Club
Re: css styles
« Reply #1 on: May 19, 2020, 05:17:20 PM »

Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,113
  • Master of BBC Abuse
Re: css styles
« Reply #2 on: May 19, 2020, 05:18:56 PM »
Use the uncompressed files inside Themes/default/css: index.css, etc. These are not minified and are much easier to work with.
Once you save a modified copy, SMF 2.1 will automatically make a new minified version.

Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,113
  • Master of BBC Abuse
Re: css styles
« Reply #3 on: May 19, 2020, 05:19:24 PM »
https://unminify.com/

Or that, but it's not necessary to go through that rigmarole. ;)

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #4 on: May 19, 2020, 05:21:52 PM »
Use the uncompressed files inside Themes/default/css: index.css, etc. These are not minified and are much easier to work with.
Once you save a modified copy, SMF 2.1 will automatically make a new minified version.
But I havent found the background class in regular index.css file which is working properly, it works only on minifield file and also important! rule is not solving the issues.  :-\

Online SychO

  • Lead Customizer
  • SMF Hero
  • *
  • Posts: 1,720
  • Gender: Male
    • SychO9 on GitHub
    • SychO
Re: css styles
« Reply #5 on: May 19, 2020, 05:23:31 PM »
Use the uncompressed files inside Themes/default/css: index.css, etc. These are not minified and are much easier to work with.
Once you save a modified copy, SMF 2.1 will automatically make a new minified version.

Yup do this ^, don't ever modify the minified files if you do that your changes will be lost at some point in time.

And if you want to disable file compression even though it helps your forum's load speed, the setting is under Configuration > Features and Options > General > Minimize CSS and JavaScript files
Take the initiative

Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,113
  • Master of BBC Abuse
Re: css styles
« Reply #6 on: May 19, 2020, 05:25:58 PM »
But I havent found the background class in regular index.css file and also important! rule is not solving the issues.  :-\

Background is not a class as such. It's an attribute that is assigned to a class (or to a tag or an id). :)

Exactly which background are you trying to change? The best way to find the CSS for it is to right click > Inspect Element. That will tell you tag, class and/or id. You can then search for those in the CSS files.

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #7 on: May 19, 2020, 05:54:56 PM »
I must disable the inline rule and then I can insert a background image from minified file:


Offline Antechinus

  • SMF Friend
  • SMF Master
  • *
  • Posts: 25,113
  • Master of BBC Abuse
Re: css styles
« Reply #8 on: May 19, 2020, 06:12:15 PM »
Where the hell is the inline rule coming from? It's not in the markup.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 72,371
    • StoryBB/StoryBB on GitHub
Re: css styles
« Reply #9 on: May 19, 2020, 06:27:05 PM »
Link to site?

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #10 on: May 20, 2020, 03:50:23 AM »
I'm on localhost testing 2.1rc2 for a new forum before going live.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 72,371
    • StoryBB/StoryBB on GitHub
Re: css styles
« Reply #11 on: May 20, 2020, 08:45:34 AM »
That makes it awfully difficult for us to help you...

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #12 on: May 20, 2020, 09:08:56 AM »
So I must go live with the forum?
Here is another example, almost on every search to change the background it gives me minified file.


Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 59,221
  • Gender: Male
    • Kindred-999 on GitHub
Re: css styles
« Reply #13 on: May 20, 2020, 09:47:45 AM »
yes... because you are looking at the GENERATED PAGE.

As you have already been told -- making changes to the ACTUAL file (e.g. index.css) will then be taken INTO the minified version after a short time.
Making changes directly to the minified version will be LOST the next time the system updates the minified file from the actual file
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

Online SychO

  • Lead Customizer
  • SMF Hero
  • *
  • Posts: 1,720
  • Gender: Male
    • SychO9 on GitHub
    • SychO
Re: css styles
« Reply #14 on: May 20, 2020, 09:51:53 AM »
If you are designing just disable the file compression as I have instructed in my previous post.
Take the initiative

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #15 on: May 20, 2020, 10:18:27 AM »
Thanks to all for your response, you are very kind and I understand what are telling me about minified file, but searching directly into the index.css without Inspect Element is hard to find all those classes and attributes it's harder for me to change a single background or some other links colors. There are some attributes which I must disable, some to make them 50% transparent because of the image in the background.

Something similar like my other forum at http://mkreef.com but this will be a new forum about cars. 


Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 72,371
    • StoryBB/StoryBB on GitHub
Re: css styles
« Reply #16 on: May 20, 2020, 11:03:47 AM »
So turn off minified files as suggested, meaning you get served the actual index.css file.

Offline pocttopus

  • Full Member
  • ***
  • Posts: 444
  • Low pressure
    • @pocttopus on Twitter
    • mkreef.com
Re: css styles
« Reply #17 on: May 20, 2020, 11:11:09 AM »
I'll try that.
One more question. Is there any changes of the 2.1 between these two links?


Thanks.

Offline Arantor

  • Resident Overthinker
  • SMF Friend
  • SMF Legend
  • *
  • Posts: 72,371
    • StoryBB/StoryBB on GitHub
Re: css styles
« Reply #18 on: May 20, 2020, 11:36:03 AM »
Yes.

The GitHub version is a year ahead of the published version on download.simplemachines.org.

Offline Kindred

  • The Mean One
  • Support Specialist
  • SMF Legend
  • *
  • Posts: 59,221
  • Gender: Male
    • Kindred-999 on GitHub
Re: css styles
« Reply #19 on: May 20, 2020, 11:47:42 AM »
I think there are over 1000 changes...
Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.