Jump to content

Code keeps disappearing

Recommended Posts

I have an issue with my blog posts, where code keeps disappearing from the code block that is serving as a page-specific style sheet. I have a class called "subtext" that colours text. It works fine but then, a few days later, all the code disappears, making the page display incorrectly. This happens no matter how many times I go back and redo the code and happens on different pages. One of the pages is located at: https://tracytredoux.com/journal-posts/autoimmunity-explained. I have attached the code from the code block in question and you can see where the .subtext is sitting without any definition.

I'm very confused about this and would appreciate any ideas.

Thanks in advance!

<style>
  h3{font-size:1.4em; color:#c68685;  margin-bottom:-0.5em
  }
  .link{}

  .subtext
    
  
 ul {
  list-style: none;
}

ul li::before {
  content: "\2022";
  color: #c68685;
  font-weight: bold;
  display: inline-block; 
  width: 1em;
  margin-left: -1em;
}   
    
</style>

 

Link to comment
  • Replies 3
  • Views 333
  • Created
  • Last Reply

Top Posters In This Topic

Change your code to this code

<style>
  h3 {
    font-size:1.4em; 
    color:#c68685;  
    margin-bottom:-0.5em
  }
ul li {
    list-style-type: none;
}
ul li::before {
  content: "\2022";
  color: #c68685;
  font-weight: bold;
  display: inline-block; 
  width: 1em;
  margin-left: -1em;
}   
</style>

 

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment
  • 2 weeks later...
On 12/22/2021 at 9:25 AM, tuanphan said:

Change your code to this code

Thanks for your reply, @tuanphan. It looks like you have simply removed the problem classes, but I need them to be there. My issue is that the content of the class definitions keeps disappearing. So, initially it looks like this:

<style>
  h3{font-size:1.4em; color:#c84e4e;  margin-bottom:-0.5em
  }
  
  .link{
  color:#c84e4e  
  }

  .subtext{
    color:#c84e4e;
    font-size:1.1em
  }    
  
 ul {
  list-style: none;
}

ul li::before {
  content: "\2022";
  color: #c84e4e;
  font-weight: bold;
  display: inline-block; 
  width: 1em;
  margin-left: -1em;
}   

</style>

but then the content of the subtext and link classes disappears after a while, as in the initial example. Hopefully the issue is clearer now.

 

Thanks again

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.