21
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/14 13:54

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


off the topic...
but...^^;;
Quote:

Herko Coomans wrote:
Step 1b:
CSS 2.0 compliant


Quote:

from:
http://www.w3.org/TR/CSS21

Cascading Style Sheets, level 2 revision 1 CSS 2.1 Specification

4 Syntax and basic data types
4.3 Values
4.3.2 Lengths
The format of a length value (denoted by in this specification) is a (with or without a decimal point) immediately followed by a unit identifier (e.g., px, em, etc.). After a zero length, the unit identifier is optional.

From:
http://www.w3.org/TR/CSS21/fonts.html
15.3 Font family: the 'font-family' property
Style sheet designers are encouraged to offer a generic font family as a last alternative. Generic font family names are keywords and must NOT be quoted.

In the example above, the last value is a generic family name. The following generic families are defined:
'serif' (e.g. Times)
'sans-serif' (e.g. Helvetica)
'cursive' (e.g. Zapf-Chancery)
'fantasy' (e.g. Western)
'monospace' (e.g. Courier)

-------------------------------------------------------
/html/themes/default/style.css
line3
table {width: 100%; margin: 5; padding: 5; font-size: small}
To:
table {width: 100%; margin: 5px; padding: 5px; font-size: small}

After this fix, it will be valid.
------------------------------------------------------------
/html/themes/phpkaox/style.css, styleMAC.css, styleNN.css
line1
table { width: 100%; margin: 5; padding: 5; font-size: small}
To:
table { width: 100%; margin: 5px; padding: 5px; font-size: small}

line6 ( I mean not ; but : )
body { font-family: Tahoma, taipei; color;#000000; font-size: 12px}
To:
body { font-family: Tahoma, taipei; color: #000000; font-size: 12px}

line6,7,8,9
body { font-family: Tahoma, taipei; color: #000000; font-size: 12px}
a { font-family: Tahoma, taipei; font-size: 12px; text-decoration: none; color: #666666; font-style: normal}
a:hover { text-decoration: underline overline; font-family: Tahoma, taipei; font-size: 12px; color: #FF9966; font-style: normal}
td { font-family: Tahoma, taipei; color: #000000; font-size: 12px;border-top-width : 1px; border-right-width : 1px; border-bottom-width : 1px; border-left-width : 1px;}

To:
body { font-family: Tahoma, taipei, Verdana, Arial, Helvetica, sans-serif; color: #000000; font-size: 12px}
a { font-family: Tahoma, taipei, Verdana, Arial, Helvetica, sans-serif; font-size: 12px; text-decoration: none; color: #666666; font-style: normal}
a:hover { text-decoration: underline overline; font-family: Tahoma, taipei, Verdana, Arial, Helvetica, sans-serif; font-size: 12px; color: #FF9966; font-style: normal}
td { font-family: Tahoma, taipei, Verdana, Arial, Helvetica, sans-serif; color: #000000; font-size: 12px;border-top-width : 1px; border-right-width : 1px; border-bottom-width : 1px; border-left-width : 1px;}

After this fix, it will be valid.
--------------------------------------------------------
/html/themes/x2t/style.css

/* Only IE that not affect the other Browsers */
* {scrollbar-face-color: #E9E9E9; scrollbar-highlight-color: #ffffff; scrollbar-shadow-color: #E0E0E0; scrollbar-3dlight-color: #000000; scrollbar-arrow-color: #000000; scrollbar-track-color: #ffffff; scrollbar-darkshadow-color: #000000;}
hr {height: 3px; border: 3px #D68000 solid; filter: Alpha(Opacity=100,FinishOpacity=10,Style=2); width: 95%;}

Yeah...
They are supported only in case of IE...
so...
If we want to make style.css valid, we have to remove them.
(I mean scrollbar-xxxx-xxxx and filter! )

/html/themes/x2t/styleNN.css
line 17
hr {height: 1px; #D68000 solid; width: 95%;}
To:
hr {height: 1px; border: 3px #D68000 solid; width: 95%;}

After this fix, it will be valid.
-------------------------------------------------------



22
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/13 15:38

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


Quote:

An XML declaration is not required in all XML documents; however XHTML document authors are strongly encouraged to use XML declarations in all their documents. Such a declaration is required when the character encoding of the document is other than the default UTF-8 or UTF-16 and no encoding was determined by a higher-level protocol. Here is an example of an XHTML document. In this example, the XML declaration is included.
Quote:


PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">


Virtual Library


Moved to example.org.






Umm...
How about adding the XML declaration ??
(I mean:)
Is there any reason that XOOPS omit this line ??

Umm..
as for mambo
echo '$iso[1] .'"?' .'>';
    
?>
    
    


as for xaraya
echo "1.0"?>n-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">nnError$msg";


As for mambo,xaraya, all pages(maybe--;;) are strictly conforming documents..although they're pages for error message.

but... as for xoops, I think it still lacks consistency.
Quote:

A Strictly Conforming XHTML Document is an XML document that requires only the facilities described as mandatory in this specification. Such a document must meet all of the following criteria:
1,It must conform to the constraints expressed in one of the three DTDs found in DTDs and in Appendix B.

2,The root element of the document must be html.

3,The root element of the document must contain an xmlns declaration for the XHTML namespace [XMLNS]. The namespace for XHTML is defined to be http://www.w3.org/1999/xhtml.

4,There must be a DOCTYPE declaration in the document prior to the root element. The public identifier included in the DOCTYPE declaration must reference one of the three DTDs found in DTDs using the respective Formal Public Identifier. The system identifier may be changed to reflect local system conventions.

5, The DTD subset must not be used to override any parameter entities in the DTD.


ex)
-----------------------
#debug popup window

in case of XOOPS 2.0.10
/html/footer.php
$content '._LANGCODE.'" />'</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'.getcss($xoopsConfig['theme_set']).'" />'.$xoopsLogger->dumpAll().'._CLOSE.'" type="button" onclick="javascript:window.close();" />
';


/html/header.php
$content '._LANGCODE.'" />'</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'.getcss($xoopsConfig['theme_set']).'" />'.$xoopsLogger->dumpAll().'._CLOSE.'" type="button" onclick="javascript:window.close();" />
';


/html/include/cp_functions.php
$content '._LANGCODE.'" />'</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'.getcss($xoopsConfig['theme_set']).'" />'.$xoopsLogger->dumpAll().'._CLOSE.'" type="button" onclick="javascript:window.close();" />
';


in case of XOOPS 2.1.0 dev
/html/class/logger.php
$content '
                    
                    ._LANGCODE.'" />
                    '</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'
                    .
xoops_getcss($xoopsConfig['theme_set']).'" />
                    
                    '
.$this->dumpAll().'
                    
                    ._CLOSE.'" type="button" onclick="javascript:window.close();" />
                    

                    
                    ';


------------------------
/html/pmlite.php
echo ".$jump."' />";


-------------------
/html/extras/login.php
<html>
  <
head>
    <
meta http-equiv="content-type" content="text/html; charset='._CHARSET.'" />
    <
meta http-equiv="content-language" content="'._LANGCODE.'" />
    <
title>'.$xoopsConfig['sitename'].'title>
    <
link rel="stylesheet" type="text/css" media="all" href="'.XOOPS_URL.'/xoops.css" />


---------------
/html/install/index.php
DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html>


--------------------
/html/install/install_tpl.php
DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html>


-------------------
/html/modules/system/admin/blocksadmin/main.php
$dummyhtml '._LANGCODE.'" />'</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'.getcss($xoopsConfig['theme_set']).'" />
'.$myblock->getVar('title').'
'.$myblock->getContent('S'$bctype).'
'
;


--------------
/html/modules/system/admin/tplsets/main.php
$dummylayout '._LANGCODE.'" />'</span><span style="color: #007700">.</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">].</span><span style="color: #DD0000">'';


-------------------
/html/modules/system/admin/version/main.php
echo "nn";
echo 
"Content-Type" content="text/htmlcharset="._CHARSET."">n";
echo 
""</span><span style="color: #007700">.</span><span style="color: #0000BB">htmlspecialchars</span><span style="color: #007700">(</span><span style="color: #0000BB">$xoopsConfig</span><span style="color: #007700">[</span><span style="color: #DD0000">'sitename'</span><span style="color: #007700">]).</span><span style="color: #DD0000">"n";


-----------------
/html/modules/system/templates/system_redirect.html
<html>
<
head>
<
meta http-equiv="Content-Type" content="text/html; charset=<{$xoops_charset}>" />
<
meta http-equiv="Refresh" content="<{$time}>; url=<{$url}>" />
<
title><{$xoops_sitename}>title>
Resized ImageXOOPS Korean Support



23
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/12 14:45

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


Quote:

I mentioned like this:
-----------------------------------
pages with form class (ex: edituser.php)
--------------------------------


or

or

or


This kind of coding above always give us some error message like this....

document type does not allow element "input" here

Refer to this page
http://www.w3.org/TR/2002/REC-xhtml1-20020801/DTD/xhtml1-transitional.dtd

So..
If we use form classes such as XoopsTableForm(tableform.php), XoopsThemeForm(themeform.php) with XoopsFormHidden(formhidden.php),
we can never get the message," "This Page Is Valid XHTML 1.0 Transitional!" from W3 validator.

Umm...
I think there are some solutions for this problem..


fixed in XOOPS 2.1.0 dev like this.

tableform.php
$hidden "";
        
$ret $this->getTitle()."n.$this->getName()."' id='".$this->getName()."' action='".$this->getAction()."' method='".$this->getMethod()."'".$this->getExtra().">nn";
        foreach ( 
$this->getElements() as $ele ) {
            if ( !
$ele->isHidden() ) {
                
$ret .= "".$ele->getCaption();
                if (
$ele->getDescription() != '') {
                    
$ret .= ''.$ele->getDescription().''
;
                }
                
$ret .= "".$ele->render()."";
            } else {
                
$hidden .= $ele->render()."n";
            }
        }
        
$ret .= "".$hidden."nn";

themeform.php
$hidden "";
        
$required =& $this->getRequired();
        
$ret ".$this->getName()."' id='".$this->getName()."' action='".$this->getAction()."' method='".$this->getMethod()."' onsubmit='return xoopsFormValidate_".$this->getName()."();'".$this->getExtra().">n".$this->getTitle()."";
        
//$count = 0;
        
foreach ( $this->getElements() as $ele ) {
            if (!
is_object($ele)) {
                
$ret .= $ele;
            } elseif (!
$ele->isHidden()) {
                
//if ($count % 2 == 0) {
                    
$class 'even';
                
//} else {
                //    $class = 'odd';
                //}
                
$ret .= "".$ele->getCaption();
                if (
$ele->getDescription() != '') {
                    
$ret .= ''.$ele->getDescription().''
;
                }
                
$ret .= "$class'>".$ele->render()."";
                
//$count++;
            
} else {
                
$hidden .= $ele->render()."n";
            }
        }
        
$ret .= "".$hidden."nn";
        
$ret .= $this->renderValidationJStrue );

Yeah...
fixed^^...cool~~~
but not complete...

/class/xoopsform/grouppermform.php
this file also needs the same fix.

foreach (array_keys($elements) as $i) {
            if (!
is_object($elements[$i])) {
                
$ret .= $elements[$i];
            } elseif (!
$elements[$i]->isHidden()) {
                
$ret .= "$elements[$i]->getCaption();
                if (
$elements[$i]->getDescription() != '') {
                    
$ret .= '$elements[$i]->getDescription() . ''
;
                }
                
$ret .= "nn" $elements[$i]->render() . "nn";
            } else {
                
$ret .= $elements[$i]->render();
            }
        }


and
in case that we use assign() ,I think, we also should be careful to avoid this kind of mistake.

ex) contact module
/modules/contact/index.php
~~
    
$xoopsOption['template_main'] = 'contact_contactusform.html';
~~
    
$contact_form->assign($xoopsTpl);
~~

/modules/contact/templates/contact_contactusform.html
<{$contactform.javascript}>
<
form name="<{$contactform.name}>" action="<{$contactform.action}>" method="<{$contactform.method}>" <{$contactform.extra}>>
  <
table class="outer" cellspacing="1">
    <
tr>
    <
th colspan="2"><{$contactform.title}>th>
    tr>
    
    <{foreach 
item=element from=$contactform.elements}>
      <{if 
$element.hidden != true}>
      <
tr>
        <
td class="head"><{$element.caption}>td>
        <
td class="<{cycle values="even,odd"}>"><{$element.body}>td>
      tr>
      <{else}>
      <{
$element.body}>
      <{/if}>
    <{/foreach}>
    
  table>
form>


PS:
from
http://www.w3.org/TR/2002/REC-xhtml1-20020801/DTD/xhtml1-transitional.dtd

(caption?, (col*|colgroup*), thead?, tfoot?, (tbody+|tr+))>








Resized ImageXOOPS Korean Support



24
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/11 15:35

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


XHTML 1.0 Transitional or XHTML 1.0 Strict ??
( or XHTML 1.1.....lol )

Umm...
I think lots of modification needed to make XOOPS valid xhtml1.0 Strict !

Quote:

from:
http://www.zvon.org/xxl/xhtmlReference/Output/comparison.html

Following transitional elements were removed from the Strict XHTML:
applet, basefont, center, dir, font, iframe, isindex, menu, noframes, s, strike, u.
--------------------------------------------------------------------------------
Following attributes were removed from the Strict XHTML:
Attribute alink is forbidden on body.
Attribute background is forbidden on body.
Attribute bgcolor is forbidden on body, table, td, th, tr.
Attribute border is forbidden on img, object, it can be used on table.
Attribute clear is forbidden on br.
Attribute language is forbidden on script.
Attribute link is forbidden on body.
Attribute name is forbidden on form, img, it can be used on a, button, input, map, meta, object, param, select, textarea.
Attribute noshade is forbidden on hr.
Attribute nowrap is forbidden on td, th.
Attribute start is forbidden on ol.
Attribute target is forbidden on a, area, base, form, link.
Attribute text is forbidden on body.
Attribute type is forbidden on li, ol, ul, it can be used on a, button, input, link, object, param, script, style.
Attribute value is forbidden on li, it can be used on button, input, option, param.
Attribute vlink is forbidden on body.


mambo : XHTML 1.0 Transitional
xml version="1.0" encoding="iso-8859-1"?>



Official Demonstration Site - Home




    
    



xoops : XHTML 1.0 Transitional
DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<
html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<
head>
<
meta http-equiv="content-type" content="text/html; charset=ISO-8859-1" />
<
meta http-equiv="content-language" content="en" />
<
meta name="robots" content="index,follow" />
<
meta name="keywords" content="XOOPS, news, technology, headlines, xoops, xoop, nuke, myphpnuke, myphp-nuke, phpnuke, SE, geek, geeks, hacker, hackers, linux, software, download, downloads, free, community, mp3, forum, forums, bulletin, board, boards, bbs, php, survey, poll, polls, kernel, comment, comments, portal, odp, open, source, opensource, FreeSoftware, gnu, gpl, license, Unix, *nix, mysql, sql, database, databases, web site, weblog, guru, module, modules, theme, themes, cms, content management" />
<
meta name="description" content="XOOPS is an extensible, OO (Object Oriented), easy to use dynamic web content management system written in PHP. XOOPS is the ideal tool for developing small to large dynamic community websites, intra company portals, corporate portals, weblogs and much more." />
<
meta name="rating" content="general" />
<
meta name="author" content="XOOPS" />
<
meta name="copyright" content="Copyright ?2001-2004, the XOOPS.org Project" />
<
meta name="generator" content="XOOPS" />
<
title>Official XOOPS Website Powered by You!title>
<
link href="https://xoops.org/favicon.ico" rel="SHORTCUT ICON" />
<
link rel="stylesheet" type="text/css" media="all" href="https://xoops.org/xoops.css" />
<
link rel="stylesheet" type="text/css" media="all" href="https://xoops.org/themes/default/style.css" />
<
link rel="alternate" type="application/rss+xml" title="RSS" href="https://xoops.org/backend.php" />


<
script type="text/javascript">

script>
head>


xaraya : XHTML 1.0 Strict
DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<
html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<
head>
<
base href="http://www.xaraya.org/ " />
<
link rel="stylesheet" type="text/css" href="themes/xe1/style/combined_screen.css" media="screen" />
<
script type="text/javascript" src="themes/xe1/scripts/nav.js">script>
<
link rel="shortcut icon" href="themes/xe1/images/favicon.ico" type="image/x-icon" />
<
meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<
meta name="Generator" content="Xaraya :: 0.9.11" />
<
meta name="Keywords" content="" />
<
meta name="Description" content="" />
<
meta name="rating" content="General" />

<
link rel="alternate" type="application/rss+xml" title="RSS" href="http://www.xaraya.org/?theme=rss" />
<
link rel="alternate" type="text/html" title="Print" href="http://www.xaraya.org/?theme=print" />
<
link rel="EditURI" type="application/rsd+xml" title="RSD" href="http://www.xaraya.org/index.php?module=xmlrpcserver" />
<
link rel="pingback" href="http://www.xaraya.org/ws.php" />
<
link rel="Top" type="text/html" href="http://www.xaraya.org/" />
<
link rel="Parent" type="text/html" href="http://www.xaraya.org/" />
<
link rel="author" href="mailto:info@xaraya.com" />
<
link rel="contents" type="text/html" href="http://www.xaraya.org/index.php/articles/map/" />
<
link rel="search" type="text/html" href="http://www.xaraya.org/index.php?module=search" />

<
title>
Xaraya :: Welcome            title>
<
script type="text/javascript" src="http://www.xaraya.org/modules/tinymce/xartemplates/includes/tinymce/jscripts/tiny_mce/tiny_mce.js">script>
<
script type="text/javascript">
tinyMCE.init({mode "specific_textareas",theme "advanced",document_base_url "http://xaraya.com/",content_css "http://xaraya.com/themes/xe1/style/xareditor.css",width "200%"height "450px"plugins "emotions,zoom,preview,ibrowser,advlink,advhr,advimage,searchreplace,print,table"ask "true",inline_styles "true"force_p_newlines"true",theme_advanced_toolbar_location "top"theme_advanced_path_location"bottom"theme_advanced_buttons2_add "preview,zoom,ibrowser,insertdate"theme_advanced_buttons3_add "emotions,advhr,search,replace,print,tablecontrols"extended_valid_elements "ul[style|*],li[style|*],ol[style|*],table[float|style|id|name],p[float|style|id|name],dd[*],dl[*],dt[*],code,pre,th[*],blockquote/quote,a[float|style|id|name|href|title|onclick], img[float|style|class|src|border=0|alt|title|h"directionality "ltr",language "en" });script>
head>


drupal : XHTML 1.0 Strict
DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<
html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<
head>
<
title>drupal.org Community plumbingtitle>
<
meta http-equiv="Content-Style-Type" content="text/css" />
<
meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<
base href="http://drupal.org/" />
<
style type="text/css" media="all">@import "misc/drupal.css";style>
<
style type="text/css">@import url(http://drupal.org/modules/codefilter/codefilter.css);
<style type="text/css">@import url(http://drupal.org/modules/project/project.css);
<link rel="alternate" type="application/rss+xml" title="RSS" href="http://drupal.org/rss.xml" />
<
style type="text/css" media="all">@import "themes/bluebeach/style.css";style>  
<
script type="text/javascript"script>
head>


for reference:

http://www.7nights.com/asterisk/archive/2004/04/xhtml-10-strict-not-ready-for-prime-time
http://liorean.web-graphics.com/xhtml/comparison.loose-strict.html
http://www.zvon.org/xxl/xhtmlReference/Output/comparison.html
http://www.sitepoint.com/article/standards-compliant-world
http://www.sitepoint.com/article/xhtml-strict-popups
http://www.w3.org/TR/2002/REC-xhtml1-20020801/DTD/xhtml1-strict.dtd
XHTML 1.1:
http://www.w3.org/TR/xhtml11/

PS:
My grandfather died a few days ago.
so...
I'm so depressed now.
Resized ImageXOOPS Korean Support



25
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/6 19:56

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


----------------------------------------------------
pages which give us "Error:required attribute not specified"
----------------------------------------------------
Quote:

In an attribute declaration, #REQUIRED means that the attribute must always be provided, #IMPLIED that no default value is provided. [Definition: If the declaration is neither #REQUIRED nor #IMPLIED, then the AttValue value contains the declared default value; the #FIXED keyword states that the attribute must always have the default value. If a default value is declared, when an XML processor encounters an omitted attribute, it is to behave as though the attribute were present with the declared default value.

Refer to this page:
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
( Just search/find with keyword, "#REQUIRED"

ex)
1) required attribute "alt" not specified
----------------------------

%attrs;
src %URI; #REQUIRED
alt %Text; #REQUIRED
name NMTOKEN #IMPLIED
longdesc %URI; #IMPLIED
height %Length; #IMPLIED
width %Length; #IMPLIED
usemap %URI; #IMPLIED
ismap (ismap) #IMPLIED
align %ImgAlign; #IMPLIED
border %Length; #IMPLIED
hspace %Pixels; #IMPLIED
vspace %Pixels; #IMPLIED
>
--------------------------

in case of admin.php

From:

To:


To fix this,
open /html/include/cp_functions.php,
and add attribute "alt"

2) required attribute "action" not specified
-----------------------------

%attrs;
action %URI; #REQUIRED
method (get|post) "get"
name NMTOKEN #IMPLIED
enctype %ContentType; "application/x-www-form-urlencoded"
onsubmit %Script; #IMPLIED
onreset %Script; #IMPLIED
accept %ContentTypes; #IMPLIED
accept-charset %Charsets; #IMPLIED
target %FrameTarget; #IMPLIED
>
---------------------------

/html/misc.php
line 86

To:



--------To be continued---------------
Quote:

Giba wrote:
I am following daily this topic.

^^;; What a pressure!!
Resized ImageXOOPS Korean Support



26
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/6 8:47

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


------------------------------------------
pages which gives us "already defined ID error"
------------------------------------------
Quote:

An "id" is a unique identifier. Each time this attribute is used in a document it must have a different value. If you are using this attribute as a hock for style sheets it may be more appropriate to use classes (which group elements) than id (which are used to identify exactly one element).


ex)
XOOPS 2.0.10 RC
----------------page start
~~~
form1(with token1)
form2(with token2)
form3(with token3)
~~~
form#(with token#)
~~~
-----------------page end

rendered like this
----------------page start
~~~~









~~



~~~~
----------------page end

same name, same id
so
this kind of page gives us some error message during validation check!

error message:
ID "XOOPS_TOKEN_REQUEST" already defined

ex) edituser.php in case of ($op == 'avatarform')

$form = new XoopsThemeForm(_US_UPLOADMYAVATAR, 'uploadavatar', 'edituser.php', 'post', true);

$form2 = new XoopsThemeForm(_US_CHOOSEAVT, 'uploadavatar', 'edituser.php', 'post', true);

rendered like this
$form:

$form2:


same name and same id!!

error message:
ID "uploadavatar" already defined

Umm...
as you know,
when rendering,
id is determined like this.
-------
name='".$this->getName()."' id='".$this->getName()."'
------
I mean XOOPS form classes do have member variable,$_name but don't have member variable,$_id !!
in most case, it's OK!
but in some case mentioned above, it can cause error when validation check!!
Umm..
To avoid this trouble,
(At my first thought)
we may..need new variable, $_id and and new member function, getID()
because if we have them, we can designate different ID value to each case.
(especially in the case that $_id is not empty....)

------------------------------
After this modification,
we can get this message, "This Page Is Valid XHTML 1.0 Transitional!" from W3 validator.


-------------To be continued-----------
Resized ImageXOOPS Korean Support



27
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/6 7:13

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


Quote:

artigas wrote:
Hope That Helps.

Thanks a lot!!
Quote:

Gambero wrote:
Why isn't wanikoo in XOOPS Core development Team ?
......
And like you said he just need to ask. So, wanikoo: ASK!

Gambero, you are so generous!
but...my answer is "NO...more exactly NOT YET"
because I don't have enough skill and experience yet.
but
I will continue to develop myself more and more....for D-day(--;;)

Umm..
Anyway..
It's off the topic^^;;
Resized ImageXOOPS Korean Support



28
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/5 14:52

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


------------------------------------
pages with javascript
------------------------------------
ex)

/html/misc.php
line 71
29
wanikoo
Re: Let's make XOOPS valid xhtml1.0 transitional!
  • 2005/4/5 10:45

  • wanikoo

  • Not too shy to talk

  • Posts: 129

  • Since: 2003/12/27


------------------------
etc.... for some modules&blocks
-------------------------
Quote:

From http://www.w3.org/TR/xhtml1/

4.2. Element and attribute names must be in lower case
XHTML documents must use lower case for all HTML element and attribute names. This difference is necessary because XML is case-sensitive e.g.
  • and
  • are different tags.

  • ex)

    ->it gives us some error messages
    element "TD" undefined
    there is no attribute "colspan"
    there is no attribute "id"
    end tag for element "td" which is not open
    end tag for "TD" omitted
    etc...
    Quote:

    4.4. Attribute values must always be quoted
    All attribute values must be quoted, even those which appear to be numeric.

    ex)

    ->error message
    an attribute value specification must be an attribute value literal unless SHORTTAG YES is specified
    Quote:

    4.5. Attribute Minimization
    XML does not support attribute minimization. Attribute-value pairs must be written in full. Attribute names such as compact and checked cannot occur in elements without their value being specified.

    ex}

    ->error message
    "value" is not a member of a group specified for any attribute



    30
    wanikoo
    Re: Let's make XOOPS valid xhtml1.0 transitional!
    • 2005/4/5 10:44

    • wanikoo

    • Not too shy to talk

    • Posts: 129

    • Since: 2003/12/27


    --------------------------
    pages with id="xxxx[]"
    -------------------------
    Umm...
    Pages with id="xxxx[]" always gives us some error messages when validation check.
    --error messages--
    character "[" is not allowed in the value of attribute "id"
    ID "xxxx[]" already defined
    ------------------

    ex)/html/notifications.php

    system_notification_list.html
    line 13

    line 21


    Line 132, column 57: character "[" is not allowed in the value of attribute "id"

    ...>
    Umm...
    in this case( input ), attribute "id" is not mandatorily requested and we have another identifier, attribute "name".
    so..
    just remove id="del_mod[]" and id="del_not[<{$module.id}>][]"
    (or if you don't want to remove attribute "id", you can keep it by changing its value like the case,viewpmsg.php mentioned before)
    ------------------------------
    After this modification,
    we can get this message, "This Page(ex: notifications.php) Is Valid XHTML 1.0 Transitional!" from W3 validator.

    Quote:

    From http://www.w3.org/TR/xhtml1/

    4.10. The elements with 'id' and 'name' attributes
    HTML 4 defined the name attribute for the elements a, applet, form, frame, iframe, img, and map. HTML 4 also introduced the id attribute. Both of these attributes are designed to be used as fragment identifiers.

    In XML, fragment identifiers are of type ID, and there can only be a single attribute of type ID per element. Therefore, in XHTML 1.0 the id attribute is defined to be of type ID. In order to ensure that XHTML 1.0 documents are well-structured XML documents, XHTML 1.0 documents MUST use the id attribute when defining fragment identifiers on the elements listed above. See the HTML Compatibility Guidelines for information on ensuring such anchors are backward compatible when serving XHTML documents as media type text/html.

    Note that in XHTML 1.0, the name attribute of these elements is formally deprecated, and will be removed in a subsequent version of XHTML.


    C.8. Fragment Identifiers
    In XML, URI-references [RFC2396] that end with fragment identifiers of the form "#foo" do not refer to elements with an attribute name="foo"; rather, they refer to elements with an attribute defined to be of type ID, e.g., the id attribute in HTML 4. Many existing HTML clients don't support the use of ID-type attributes in this way, so identical values may be supplied for both of these attributes to ensure maximum forward and backward compatibility (e.g., ...).

    Further, since the set of legal values for attributes of type ID is much smaller than for those of type CDATA, the type of the name attribute has been changed to NMTOKEN. This attribute is constrained such that it can only have the same values as type ID, or as the Name production in XML 1.0 Section 2.3, production 5. Unfortunately, this constraint cannot be expressed in the XHTML 1.0 DTDs. Because of this change, care must be taken when converting existing HTML documents. The values of these attributes must be unique within the document, valid, and any references to these fragment identifiers (both internal and external) must be updated should the values be changed during conversion.

    Note that the collection of legal values in XML 1.0 Section 2.3, production 5 is much larger than that permitted to be used in the ID and NAME types defined in HTML 4. When defining fragment identifiers to be backward-compatible, only strings matching the pattern [A-Za-z][A-Za-z0-9:_.-]* should be used. See Section 6.2 of [HTML4] for more information.

    Finally, note that XHTML 1.0 has deprecated the name attribute of the a, applet, form, frame, iframe, img, and map elements, and it will be removed from XHTML in subsequent versions.




    TopTop
    « 1 2 (3) 4 5 6 ... 12 »



    Login

    Who's Online

    202 user(s) are online (90 user(s) are browsing Support Forums)


    Members: 0


    Guests: 202


    more...

    Donat-O-Meter

    Stats
    Goal: AU$15.00
    Due Date: Jul 31
    Gross Amount: AU$0.00
    Net Balance: AU$0.00
    Left to go: AU$15.00
    Make donations with PayPal!

    Latest GitHub Commits