Looking for alternate CSS syntax

I find this syntax not too nice:
<a id="htmlLink" class="button inline btnNotification iframe complete"...>

What alternatives are there?

How about in C#, how could I realize the same result with the fluent CSS API?

Thanks.
newbiewebSr. Software EngineerAsked:
Who is Participating?
 
COBOLdinosaurCommented:
addAttr look like it might be an alias for the setAttribute method of the DOM.  It suggests that the styling is being generated dynamically as a one-off instead of using a stylesheet.  In my opinion, that would create some debugging and maintenance issues, but I don't know C# so maybe that is a viable approach.


I would like to learn PHP, sometime soon...

It is easy to learn the basics, and anyone who has coded javascript already know most of the syntax.  The best part is that it is open source and free, so there is a huge amount of support, and a lot of scripts already written an available to be plugged into projects.

Iam starting to sound like a promoter so I better shut up before Mircrosoft gets mad at me. ;)
0
 
COBOLdinosaurCommented:
I have no Idea how it would ever be necessary to use that many classes for a single link.  I think you may need to consolidate you stylesheets a little.
0
 
newbiewebSr. Software EngineerAuthor Commented:
OK. Then why not create one that's more normal, then show me how to code the same thing using the CSS fluent API?
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 
COBOLdinosaurCommented:
What alternatives are there?

I gave you the best alternative... clean up your CSS.  

If you want me to show you how then post the CSS that forces you to uses that many classes.  The way it is you might as well be hardcoding the stlye in the tag.

As for C#, I have never written a singe line of code using C#.  It is not something I would ever use instead of PHP.
0
 
newbiewebSr. Software EngineerAuthor Commented:
That was sample CSS, not from my program. I was trying to learn other ways to concatenate classes, aside from just putting a space between them.

Sorry, maybe this fluent API is C# and not CSS. I have seen it before.

is uses
.addAttr() or something of the like.

or add('attr', 'iframe');

I wish I'd saved it when I saw it. Do you know what I am talking about?

I would like to learn PHP, sometime soon...
0
 
newbiewebSr. Software EngineerAuthor Commented:
Thanks for the help. I knew nothing about PHP but now know it's like JavaScript, which I really like. See you on the PHP boards!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.