Ok, I need a new thread for my HTML processing program

Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
2 replies · 1K views
Jamin2112
Messages
973
Reaction score
12
My old thread was getting messy and I realized I needed to go back to square 1 and write up a plan. So here's an outline of the plan:
23m5t04.jpg


2t5r7.jpg


I will add to this thread as I write the helper functions and encounter any problems. Criticism greatly appreciated.
 
Physics news on Phys.org
And here's my self-explanatory procedure for writing the formatted CSS into a string:

2uq2mo1.jpg
 
Im not really sure if this is relevant for you or not, but in general you would probably not want to structure a CSS file like you do above. If you do, then it is similar to inserting style="" attributes on each elements (this is similar to the naive way of formatting a word document by applying style directly to each chunk of text).

CSS usually shines best when your style classes only depends on one or two levels of html structure context above the current element, although sometimes more is required when you need to adjust a specific frameworks use of CSS in one particular situation. Using CSS the "right way" is similar to formatting a word document by tagging paragraphs as body text, headlines, etc. and they style those tags instead.