Is There an Alternative to CSS

Is there an alternative to CSS?

CSS is the only real option.

Browser support for CSS should not be a major concern (in most cases) once you learn the ins & outs of CSS. The key to understand about CSS is that its purpose is to define the style of an HTML document and it should be separate from the content.

You'll need practice in learning how to make things degrade gracefully in browsers that don't support features. The basic idea here is that you should make the lowest common denominator (Internet Explorer usually) work "good enough" that it doesn't take away from the user experience, and provide the niceties for users with better browsers. Also, don't develop for Internet Explorer first. Leave it until last, then fix its bugs. Doing things the other way around (IE first) is much harder.

You also have the option of using JavaScript to set styles, but that is not recommended because you should avoid applying styles within JavaScript since JavaScript is meant for logic, not styles.

There are 3 (depending how you look at it) components to a web page:

  • HTML - for content
  • CSS - for styling your content
  • JavaScript - for applying additional or dynamic logic to your content

What are some alternatives to CSS to style your websites?

CSS is broken, but the best way is still CSS.

While CSS itself may have flaws and missing features and be generally crappy, and while it may not work the same in every browser, it's still the best tool for the job. Its still an extremely flexible tool, albeit a slightly broken one.

CSS alternative to the CSS plus sign selector?

If you really want to support IE8- (which doesn't support + selector) I'd recommend you to use polyfill.

Is there an alternative to body or container tags in HTML and CSS?

  1. You don't need the body styling that he put on the tutorial, it is just there
    to center content on the screen so we can see it better.
  2. If you have a .container class already in your code, you can always change the
    name of the class to card-container or new-container or
    whatever you think is suitable.

.card-container {
position: relative;
width: 1100px;
display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap;
padding: 30px;
}

.card-container .card {
/*
Styling for card
*/
}

CSS alternative to li:has(+ .class) relational pseudo class and li:not(.class ~ li)

Is there any combination of pseudo classes and selectors that could do the trick in pure CSS?

There isn't; the reason :not(.centered ~ li) doesn't work is indeed that it only currently supports simple selectors — like :has(), :not() will only accept combinators in Selectors 4. Since there are no pseudo-classes that currently accept combinators, and the only available sibling combinators go forward, you are left with a very restricted domain language in this regard. This is why those additions to Selectors were made.

As for progress... progress on the :has() pseudo-class has been eh. Last I heard, the working group was still deciding between allowing a subset of :has() in CSS or separating that out into its own pseudo-class, and vendors were going to see how much of it they could implement in CSS for this to work. But I don't think there has been any data yet.

Alternatives to HTML for website creation?

There are actually several solutions that allow you to nearly completely avoid CSS and HTML.

GWT: Google Web Toolkit

Written in Java and will allow you to build both server and client code in Java. Used to build Google Wave.

Cappuccino and Objective-J:

Objective-J is to JavaScript as Objective-C is to C. It extends JavaScript with many near features, including type-checking, classes and types.
Cappuccino is like Cacoa (Mac OS X GUI toolkit).
Using these two you can build incredibly rich and desktop like webapps. They run mostly on the client side and you can use whatever you want on the server.
A good example is 280slides

SproutCore is similar to Cappuccino, but it uses pure JavaScript instead. Apple is using SproutCore to make me.com.

I should also mention that knowledge to HTML, CSS, JavaScript is a good skill to know, just like understanding your compiler is a good skill.

EDIT:
As said above Adobe Flash can also be used.

Is there an alternative to the CSS white-space property for use in IE 7?

IE7 doesn't support the white space handling property pre-line. See this page for a compatibility table.

You can use these declarations instead

white-space: pre;
word-wrap: break-word;

It's not an alternative to pre-line, as it's breaking words not lines but at least the content does not exceed the boundaries of its container.

Is there a target=_blank alternative in css?

This is not a css property, so you won't find a css equivalent.
It's a behavioral attribute, similar to click

You can target these elements and select them using java script though and apply whatever style you need.



Related Topics



Leave a reply



Submit