[Phpmyadmin-devel] [phpMyAdmin] Re: Multi-language support
Robin Johnson
robbat2 at fermi.orbis-terrarum.net
Mon May 7 01:25:23 CEST 2001
On Sun, 6 May 2001, [iso-8859-1] Loïc wrote:
> >For the majority of my recent projects I have validating
> >against the XHTML 1.0 Transitional DTD, and I find it
> >renders nicely in the great majority of browsers out there,
> >bar a few really old netscapes and IE's.
> >Having a DTD and conforming to it 100% would be a
> >majority improvment to our code.
> You have my fully agreement on this point :)
I'm going to start a conversion over into using XHTML & add the DTD tags
myself. A few minor guidelines to anybody doing more work can be seen
here. http://www.w3.org/TR/xhtml1/. XHTML 1.1 is already in the works, but
it won't be too much of a change once we have have XHTML 1 working.
A quick summary of XHTML precautions to take:
ALL tags are lowercase.
tags must NOT overlap
ALL tags must exist either as a pair <li></li> OR as a tag with a trailing
slash <br /><img />. The trailing slash method is recommended due to how
NN handles </br>.
ALL attributes must be quoted, double quotes are preferred. <img
src="boo.png" />
Attributes must be NOT minimized
<dl compact="compact">
All script elements must either be wrapped with a CDATA or made external.
<script> <![CDATA[ ... unescaped script content ... ]]> </script>
See this document for the definetive list:
http://www.w3.org/TR/xhtml1/#diffs
Our offical DTD header block is now
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html
PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
With the nessecary substitutions per language in 'encoding', 'xml:lang'
and 'lang'.
> Well the only things that may differ inside the stylesheet
> from one language to another are the font face and the
> font size. Then I'm not sure three file are required.
> Moreover you know how crappy is NN4 with CSS:
> for example a child selector rarely inherit the rules applied
> to its parent. In our case it means the font face may have
> to be repeated inside each of the selector defnition.
> With this is mind, I'm unfortunatly not sure a common css can be used.
> Actually we faced the problem with
> phpMyChat, that's the reason why I can detail.
The idea I had, there exists a common CSS file, that does NOT comply for
the NN4 parent bug. The PHP file reads it in, and spits out a new one that
is complete, rather like the CSS validator by W3. As a result, we only
have to maintain the common one and one per language, and the PHP file
spits out a combined one, that could even be customized per browser.
Text direction and font face are a function of the character set.
Thus we only need to know the character set to call the stylesheet.php.
<?php
$css_url = "/stylesheet.php?charset=".urlencode($charset);
?>
<link rel="stylesheet" type="text/css" href="<?php echo $css_url; ?>" />
> >Veni, Vidi, Conferotuli
> Veni, Vidi, Vinci... quid nomino leo :p
> (I came, I saw, I won... because I'm the Lion)
LoL.
Anybody else have some interesting latin epithets to add?
>
> ______________________________________________________________________________
> ifrance.com, l'email gratuit le plus complet de l'Internet !
> vos emails depuis un navigateur, en POP3, sur Minitel, sur le WAP...
> http://www.ifrance.com/_reloc/email.emailif
>
>
>
> _______________________________________________
> Phpmyadmin-devel mailing list
> Phpmyadmin-devel at lists.sourceforge.net
> http://lists.sourceforge.net/lists/listinfo/phpmyadmin-devel
>
--
---
Robin Hugh Johnson
"Robbat2"
QTOD: "I used to be an idealist, but I got mugged by reality."
E-Mail : robbat2 at orbis-terrarum.net
ICQ# : 30269588 or 41961639
Home Page : http://www.orbis-terrarum.net
Time Zone : Pacific Daylight (GMT - 8)
-----GEEK CODE-{---
Version: 3.12 Serial: 2001041400
GU/CS d- a--- C++++ L++++ U*+++ E----
e* h! tv-- X+ W+++ N+++ w--- M P+ R O-
D++ V-- PS+ PE-- Y+ PGP++ r !y t-- 5
s+:- b+++
---}-GEEK CODE-----
-----PGP INFO-{---
Key ID:0x7E20DFA1
FingerPrint:
5447C73A 30FB144C 89521B69 2D6A615E 7E20DFA1
---}-PGP INFO-----
More information about the Developers
mailing list