Mark-up standards in Modules
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Mark-up standards in Modules
As a long-time user of CMSMS now, I've noticed that the standard of mark-up varies quite radically between modules; some are very good, semantic and accessible, while others are less so.
I think that good HTML is just as important as good CSS and good PHP, and I think there should be a consultant to help module developers release excellent mark-up. As my PHP is somewhat lacking and I'm keen to help out, I'd like to volunteer for that position.
I think that good HTML is just as important as good CSS and good PHP, and I think there should be a consultant to help module developers release excellent mark-up. As my PHP is somewhat lacking and I'm keen to help out, I'd like to volunteer for that position.
Re: Mark-up standards in Modules
stopsatgreen,
I have produced a couple of modules and thus consider myself a module developer. I have used Google to find out what the definition is of mark-up. I couldn't find one that would fit anything to do with PHP.
Please give me some input on what you mean by mark-up.
PS. I have the idea that it has to do with the html that is prepared out of the templates in combination with PHP.
I have produced a couple of modules and thus consider myself a module developer. I have used Google to find out what the definition is of mark-up. I couldn't find one that would fit anything to do with PHP.
Please give me some input on what you mean by mark-up.
PS. I have the idea that it has to do with the html that is prepared out of the templates in combination with PHP.
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
Exactly that; the HTML that is produced from the module templates.
Re: Mark-up standards in Modules
I've noticed that, too.
Every module uses its own output such as CSS id or classnames (or even markup) so everytime you installed a module you need to restyle your page.
Some time ago i started a project to change the id/classnames of HTML elements "on the fly".
So before HTML output will be sent to the browser a module called UniformStyle uses regexp to change classnames/ids of specified HTML elements.
e.g. all input elements of type text could get the classname "textinput".
But i got stuck with it so there are still no files released.
If every module uses a standard ouput scheme it would be much more easier to style a website and to make it valid, semantic and accessible.
So what about a list of "rules" of module oupt that can be shown in a sample module (e.g. the skeleton module?).
Every module uses its own output such as CSS id or classnames (or even markup) so everytime you installed a module you need to restyle your page.
Some time ago i started a project to change the id/classnames of HTML elements "on the fly".
So before HTML output will be sent to the browser a module called UniformStyle uses regexp to change classnames/ids of specified HTML elements.
e.g. all input elements of type text could get the classname "textinput".
But i got stuck with it so there are still no files released.
If every module uses a standard ouput scheme it would be much more easier to style a website and to make it valid, semantic and accessible.
So what about a list of "rules" of module oupt that can be shown in a sample module (e.g. the skeleton module?).
Re: Mark-up standards in Modules
Lets take an example.
Is it valid to use/prepare a table with data out of a module?
Is it valid to use/prepare a table with data out of a module?
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
Of course, if it's tabular data.
But what I'm more concerned about is ways to make the tables accessible; using captions, summaries and headers where necessary, making sure the order is head-foot-body, that kind of thing.
Or it could be adding WAI-ARIA data to forms; making sure they have fieldsets and labels and legends; anything to make them more accessible, and to add extra hooks for designers/developers.
Some modules don't need this; some, in my opinion, do.
But what I'm more concerned about is ways to make the tables accessible; using captions, summaries and headers where necessary, making sure the order is head-foot-body, that kind of thing.
Or it could be adding WAI-ARIA data to forms; making sure they have fieldsets and labels and legends; anything to make them more accessible, and to add extra hooks for designers/developers.
Some modules don't need this; some, in my opinion, do.
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
What does anybody else think about this? How do I start?
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
When I filed a bug in one of the modules, saying that the mark-up it produced wasn't valid or accessible, I did not expect to get the reply that it wasn't an issue because the user could sort it out afterwards! GOOD MARK-UP IS ESSENTIAL TO A GOOD WEBSITE. I am sure the developers of CMSMS wouldn't write bad, lazy PHP code, so why shouldn't client-side developers get good code out of the box?
This convinces me that there is a need for a consultant to over-see markup standards. I'm offering my time to fill that role. Does no-one have an opinion on it? Where do I start?
This convinces me that there is a need for a consultant to over-see markup standards. I'm offering my time to fill that role. Does no-one have an opinion on it? Where do I start?
Re: Mark-up standards in Modules
Good point.stopsatgreen wrote: When I filed a bug in one of the modules, saying that the mark-up it produced wasn't valid or accessible, I did not expect to get the reply that it wasn't an issue because the user could sort it out afterwards! GOOD MARK-UP IS ESSENTIAL TO A GOOD WEBSITE. I am sure the developers of CMSMS wouldn't write bad, lazy PHP code, so why shouldn't client-side developers get good code out of the box?
This convinces me that there is a need for a consultant to over-see markup standards. I'm offering my time to fill that role. Does no-one have an opinion on it? Where do I start?
This is an info only.
In Italy there is a law that it's mandatory for public amdministrations/government site to be close at (about) WAI 1.0
In Italian forum we have a topic with pratical tips only on various modules (essentialy core) to make them accessible but it is clear that in general, must be repeated for each update
Alby
Re: Mark-up standards in Modules
I remember that there was a thread that discussed the measurement of the quality of modules. I just checked the quick tipshttp://www.w3.org/WAI/quicktips/Overview.php and think that at least these tips should be part of measuring a particular modules quality.
Wouldn't you say that this will help the mark up to become better?
Why not take one of the tips and make sure that one is available in the module otherwise the module is not excepted as a downloadable one? But this will drive people away from making module (or releasing them to others).
Duketown
Wouldn't you say that this will help the mark up to become better?
Why not take one of the tips and make sure that one is available in the module otherwise the module is not excepted as a downloadable one? But this will drive people away from making module (or releasing them to others).
Duketown
Re: Mark-up standards in Modules
The idea that all modules should have a standard like "e.g. all input elements of type text could get the classname "textinput"." would make it kind of hard to style correctly if you had more than one in a page or more than one module on a page, most modules have some kind of ID on things that can be used to style items inside them...
I've never had a problem styling modules to fit the needs of my customers...
I've never had a problem styling modules to fit the needs of my customers...
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
That's not really what I'm referring to; I don't mean at this stage to standardise class names and IDs. What I mean is to make sure that all HTML that is output is valid and accessible, which is not happening at the moment. Some things are small bugs which invalidate the code - such as not escaping - and some are more for accessibility - such as not using to associate labels with inputs.mark wrote:The idea that all modules should have a standard like "e.g. all input elements of type text could get the classname "textinput".
It's just not good enough to say that it's the user's responsibility to sort these things out; we should give users valid, accessible HTML from the moment they install a module.
As a second step, we could go even further by implementing Microformats (http://www.microformats.org/) in the mark-up, and using WAI-ARIA (http://www.w3.org/WAI/intro/aria) for form elements. It would be a big plus for the project as a whole.
Re: Mark-up standards in Modules
Yes, but these IDs are generated by the core and depends on the modules position.mark wrote: The idea that all modules should have a standard like "e.g. all input elements of type text could get the classname "textinput"." would make it kind of hard to style correctly if you had more than one in a page or more than one module on a page, most modules have some kind of ID on things that can be used to style items inside them...
If you wrap these modules in a div or span with an own id you will be able to style the elements correctly, too.
No matter which id will be used in the modules output.
Even if you have several modules with the same html elements (e.g. ) or one modul is used several times you want a uniform style of your page.
I don't like to style each single element seperately.
If i have a layout i say "Input elements have this color and that fontsize, and buttons have...".
If some modules should have a diferent look i can use the "wrappers id" and override the previous styles.
But maybe this is just my personal way of creating layouts.
I just recognized in other cms when installing modules there is no need of adapting the layout (css) of modules output since there are some standards.
It was just an idea, because i think this would make creating a good looking website with cms ms much more easier.
-
- Power Poster
- Posts: 322
- Joined: Sat Feb 04, 2006 1:24 am
- Location: London, England
Re: Mark-up standards in Modules
@ NaN: I agree, but I think this should be a later step. First step is to make sure that the mark-up is valid, and accessible; next steps, that it is meaningful, and consistent.
I'm offering my time to do this, but I haven't heard anything back from developers yet.
I'm offering my time to do this, but I haven't heard anything back from developers yet.