Make better code !

General project discussion. NOT for help questions.
Post Reply
piratos

Make better code !

Post by piratos »

Input , Output that are the things why a programmer had a lot of work.

But only a good input is only the half work.

Do not make the mistakes of other cms - systems !

A fresh installed 0.7.1 shows 8 errors with the w3c validator 0.6.7, the admin-page 5 errors.

The cms is xhtml 1.0 trans the adminpages 4.01 trans.

100% correct html increase the speed of a complex web about 40% and there is no random view given by the browser.

So it is commendable to install the w3c - validator local and check the output by the fly if you are at work.
piratos

Make better code !

Post by piratos »

i have you send a mail with changes in htmlarea.js, page.functions.php and editcontent.php.

So admin-> Content Managment -> Edit Content is 100% valid html.
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Make better code !

Post by Ted »

Cool. Thanks. I'll put them up later on today.
piratos

Make better code !

Post by piratos »

Here are the errors viewed by index.php (fresh install).



Line 201, column 75: document type does not allow element "link" here

...layers/layersmenu-cms.css" type="text/css">


----------------------

And this is the reason in function.dhtmlmenu.php - link was set within the body not in the mety-tags - plugin must be changed !

$text = '
etc etc,
-----------------------------------------------------------------------------------------------

Another html errors with index.php

..cmsmodule_1_type=rss&CMSSESSID=dc75e7a74f228eda09419cdea2feddd5"><img
It was the &CMSSESSID - must be & ....
I don't find it (module.functions.php ??)
piratos

Make better code !

Post by piratos »

I have send ypu a new bulletmenu with little images.

It works without ul and li and with separator without xhtml - errors by itself.
piratos

I have found the bug

Post by piratos »

I have found it in lib/module.functions.php

wrong:
function cms_mapi_register_execute_function($name, $function) {
global $gCms;
$cmsmodules = &$gCms->modules;
if (isset($cmsmodules[$name])) {
$cmsmodules[$name]['execute_function'] = $function;
}
}

correct
function cms_mapi_register_execute_function($name, $function) {
global $gCms;
$cmsmodules = $gCms->modules;
if (isset($cmsmodules[$name])) {
$cmsmodules[$name]['execute_function'] = $function;
}
}
Knaldgas

Compliance still bad...

Post by Knaldgas »

Hi all,

I have just done a fresh install of 0.7.3, and it seems like there's still some issues to be compliant :oops:
Should be pretty straight forward to check: http://validator.w3.org/ and enter your favorite CMS Made Simple site.

Any chance of this is being fixed?

/Knaldgas
Akrabat

Make better code !

Post by Akrabat »

I only see two errors:

1. a section in the (due to dhtmlmenu)
2. problems with PHP auto addition of SESSION ID to every link.


According to http://martin.f2o.org/php/session, PHP's transparent session support should be turned off anyway, so I did in .htaccess :) Adding ini_set('session.use_trans_sid', false); just before calling session_start() would also work.

The {dhtmlmenu} problem is not easy to fix though :(
Post Reply

Return to “General Discussion”