Символы "<" и ">" запрещены в тексте между тегами (гм-м... не владею
Символы "<" и ">терминологией...).
Чем их можно заменять? Про html'овские < и > знаю. Есть еще варианты? Как
это избегается в других языках?
`-._ --- Alexander Kocharin ---
Для <:
HTML: Decimal: > Named: >
JavaScript: Unicode: \u003E
CSS: Unicode: \3E or \00003E
PS. взял тут:
http://www.saila.com/usage/tips/examples/special_characters.html
____________________________
С уважением, Коренской Антон
AK> Чем их можно заменять? Про html'овские < и > знаю. Есть еще
AK> варианты? Как это избегается в других языках?
посмотри в сторону CDATA (не вполне понял в чем вопрос :0) но возможно это
то что тебе нужно)
В твоем письме от 30.01.2007 22:00 было написано:
> Символы "<" и ">" запрещены в тексте между тегами (гм-м... не владею
> терминологией...).
> Чем их можно заменять? Про html'овские < и > знаю. Есть еще варианты?
А чем не устраивает? Это стандарт для любого эхотага.
Можно еще юзать < и >.
> Как это избегается в других языках?
В каких?
--
Счастливой Пачи - Myr
PGP Key ID 0x9A5F7D45, Fingerprint 7mnP6DcSsH+0xFaaTVxR75pffUU=
>> Символы "<" и ">" запрещены в тексте между тегами (гм-м... не владею
>> терминологией...). Чем их можно заменять? Про html'овские < и
>> > знаю. Есть еще варианты?
RNNK> А чем не устраивает? Это стандарт для любого эхотага.
Так уж для любого?
>> Как это избегается в других языках?
RNNK> В каких?
Ну на базе xml существует много языков...
RNNK>> А чем не устраивает? Это стандарт для любого эхотага.
AK> Так уж для любого?
Эхотаг, для которого < означает что-либо, отличное от <, не
является таковым.
--
Miguel migue...@yandex.ru
LJ migmit http://miguel-0.narod.ru
RNNK>>> А чем не устраивает? Это стандарт для любого эхотага.
AK>> Так уж для любого?
MM> Эхотаг, для которого < означает что-либо, отличное от <, не
MM> является таковым.
И это даже написано в спецификации xml?
Так было 00:43 31 Jan 07 написано от Alex Kocharin к All:
AK> Символы "<" и ">" запрещены в тексте между тегами (гм-м... не владею
AK> терминологией...).
AK> Чем их можно заменять? Про html'овские < и > знаю. Есть еще
AK> варианты? Как это избегается в других языках?
В URLах их заменяют шестнадцатиричным кодированием символов.
======= Hачало цитаты из файла rfc1738.txt =======
Network Working Group T. Berners-Lee
Request for Comments: 1738 CERN
Category: Standards Track L. Masinter
Xerox Corporation
M. McCahill
University of Minnesota
Editors
December 1994
Uniform Resource Locators (URL)
[ /_*... и скип ... долгий, зловещий скип ...*_/ ]
Unsafe:
Characters can be unsafe for a number of reasons. The space
character is unsafe because significant spaces may disappear and
insignificant spaces may be introduced when URLs are transcribed or
typeset or subjected to the treatment of word-processing programs.
The characters "<" and ">" are unsafe because they are used as the
delimiters around URLs in free text; the quote mark (""") is used to
delimit URLs in some systems. The character "#" is unsafe and should
always be encoded because it is used in World Wide Web and in other
systems to delimit a URL from a fragment/anchor identifier that might
follow it. The character "%" is unsafe because it is used for
encodings of other characters. Other characters are unsafe because
gateways and other transport agents are known to sometimes modify
such characters. These characters are "{", "}", "|", "\", "^", "~",
"[", "]", and "`".
All unsafe characters must always be encoded within a URL. For
example, the character "#" must be encoded within URLs even in
systems that do not normally deal with fragment or anchor
identifiers, so that if the URL is copied into another system that
does use them, it will not be necessary to change the URL encoding.
======= Конец цитаты из файла rfc1738.txt =======
======= Hачало цитаты из файла FidoURL.txt =======
**********************************************************************
FGHI FIDONET GLOBAL HYPERTEXT INTERCHANGE
**********************************************************************
Status: draft
Revision: 0.3
Title: FGHI URL, the set of Uniform Resource Locators
for Fidonet objects and services
Author: Mithgol the Webmaster (Sergey Sokoloff, 2:5063/88)
Special thanks to: Shannar (Boris Kassal, 2:463/587)
Trooper (Alexey Bezugly, 2:5030/1520.9)
NoSFeRaTU (Konstantin Kuzov, 2:5019/40.1)
Revision Date: 22 Jan 2007
-+--------------------------------------------------------------------
[ /_*... и скип ... долгий, зловещий скип ...*_/ ]
5.2.2.2. Unsafe characters
-+------------------------
Characters can be unsafe for a number of reasons.
The space character is unsafe because significant spaces may
disappear and insignificant spaces may be introduced when URLs
are transcribed or typeset or subjected to the treatment of
word-processing programs. The octet 20 hexadecimal MUST always
be encoded.
The characters "<" and ">" are unsafe because they are used
as the delimiters around tags in HTML hypertext and XML data.
The octets 3C and 3E hexadecimal MUST always be encoded.
======= Конец цитаты из файла FidoURL.txt =======
Ceterum censeo Diptaunum esse delendam! [Ru.Mozilla] http://Mithgol.Ru/
Mithgol the Webmaster. [Team В эхолисте ,,ё`` уместим] [Team А я меняю subj]
... - Для меня вы все на одно лицо, ─ сказал Мэйс Винду поверженному им клону.
В твоем письме от 31.01.2007 18:10 было написано:
> RNNK>>> А чем не устраивает? Это стандарт для любого эхотага.
> AK>> Так уж для любого?
> MM> Эхотаг, для которого < означает что-либо, отличное от <, не
> MM> является таковым.
> И это даже написано в спецификации xml?
Да.
<blockquote cite="http://www.w3.org/TR/2006/REC-xml-20060816/#syntax">
The ampersand character (&) and the left angle bracket (<) MUST NOT appear in
their literal form, except when used as markup delimiters, or within a comment,
a processing instruction, or a CDATA section. If they are needed elsewhere,
they MUST be escaped using either numeric character references or the strings
"&" and "<" respectively. The right angle bracket (>) may be represented
using the string ">", and MUST, for compatibility, be escaped using either
">" or a character reference when it appears in the string "]]>" in content,
when that string is not marking the end of a CDATA section.
</blockquote>
MM>> Эхотаг, для которого < означает что-либо, отличное от <, не
MM>> является таковым.
AK> И это даже написано в спецификации xml?
Конечно. Точную ссылку ищи сам.
MtW> Characters can be unsafe for a number of reasons. The space
MtW> character is unsafe because significant spaces may disappear and
MtW> insignificant spaces may be introduced when URLs are transcribed or
MtW> typeset or subjected to the treatment of word-processing programs.
MtW> The characters "<" and ">" are unsafe because they are used
Может, may be used? Они же далеко не всегда используются...
MtW> The space character is unsafe because significant spaces may
MtW> disappear and insignificant spaces may be introduced when
MtW> URLs
MtW> are transcribed or typeset or subjected to the treatment of
MtW> word-processing programs. The octet 20 hexadecimal MUST always
MtW> be encoded.
// offtopic:
How can it be encoded? Практика "+" распространяется?
>> RNNK>>> А чем не устраивает? Это стандарт для любого эхотага.
>> AK>> Так уж для любого?
>> MM> Эхотаг, для которого < означает что-либо, отличное от <, не
>> MM> является таковым.
>> И это даже написано в спецификации xml?
> Да.
> <blockquote cite="http://www.w3.org/TR/2006/REC-xml-20060816/#syntax">
Спасибо.
В четверг, 01-го февраля 2007, примерно в 14:39, Alex беседовал с Mithgol:
MtW>> The octet 20 hexadecimal MUST always be encoded.
AK> How can it be encoded? Практика "+" распространяется?
Кодируется элементарно - "%20". "+" - ИМХО, внутренняя реализация скрипта,
остальные понимать не обязаны. Так кодируется просто разделитель, которым может
быть и пробел и что угодно другое.
─────-─────-────-───-──-─-─ За сим навеки и прочее ─-─-──-───-────-─────-─────
... В ответ на неизвестно кем совершенные террористические акты, США нанесли
Так было 14:39 01 Feb 07 написано от Alex Kocharin к Mithgol the Webmaster:
MtW>> Characters can be unsafe for a number of reasons. The space
MtW>> character is unsafe because significant spaces may disappear and
MtW>> insignificant spaces may be introduced when URLs are transcribed or
MtW>> typeset or subjected to the treatment of word-processing programs.
MtW>> The characters "<" and ">" are unsafe because they are used
AK> Может, may be used? Они же далеко не всегда используются...
Этакие вопросы прошу адресовать сэру рыцарю Бернерсу-Ли, а также прочим йоменам
из Ксерокса и Миннесотского Университета. То есть составителям RFC 1738.
А я это определение в свой черновик стандарта FGHI URL перетащил дословно,
разумно стремясь ко взаимной совместимости стандартов по этому вопросу.
MtW>> The space character is unsafe because significant spaces may
MtW>> disappear and insignificant spaces may be introduced when
MtW>> URLs
MtW>> are transcribed or typeset or subjected to the treatment of
MtW>> word-processing programs. The octet 20 hexadecimal MUST always
MtW>> be encoded.
AK> // offtopic:
AK> How can it be encoded? Практика "+" распространяется?
Да. (c)
Ибо сказано также:
======= Hачало цитаты из файла FidoURL.txt =======
**********************************************************************
FGHI FIDONET GLOBAL HYPERTEXT INTERCHANGE
**********************************************************************
Status: draft
Revision: 0.3
Title: FGHI URL, the set of Uniform Resource Locators
for Fidonet objects and services
Author: Mithgol the Webmaster (Sergey Sokoloff, 2:5063/88)
Special thanks to: Shannar (Boris Kassal, 2:463/587)
Trooper (Alexey Bezugly, 2:5030/1520.9)
NoSFeRaTU (Konstantin Kuzov, 2:5019/40.1)
Revision Date: 01 Feb 2007
-+--------------------------------------------------------------------
[ /_*... и скип ... долгий, зловещий скип ...*_/ ]
5.2.2.4. The plus ("+") and the encoding of white spaces
-+------------------------------------------------------
White spaces (octets 20 hexadecimal) are the most common
unsafe characters in Fidonet, and so they play a significant
role in some scheme-specific parts of the URL: they appear in
MSGID kludges, they are used as delimiters between words
in lines of text, etc.
To enhance human readability of Fidonet URLs, and to make them
shorter, a new shorter synonym for "%20" hexadecimal triplet
is available. It is the plus sign ("+").
Programs interpreting scheme-specific part of Fidonet URL
MUST treat the character plus ("+") there as equivalent
to the white space hexadecimal triplet ("%20").
Because of that, the plus character itself is reserved, and
its own corresponding octet (2B hexadecimal) MUST be encoded
if it appears in scheme-specific part of Fidonet URL.
5.2.2.4.1. Specificity note
-+-------------------------
The rule of equivalence between "+" and "%20" does not apply
outside of the scheme-specific part of URL; the plus sign
has no special meaning in scheme name, since white spaces
are not allowed in scheme names.
5.2.2.4.2. Internet practice note
-+-------------------------------
The same shortening already happens in Internet. Open
http://www.google.ru/search?q=Fidonet+URL URL, and you'll
get the Google search for "Fidonet URL" (not "Fidonet+URL");
http://www.google.ru/search?hl=ru&q=Fidonet%2BURL is needed
if you're looking for "Fidonet+URL".
This practice is not documented in RFC 1738. It is, however,
documented in RFC 1630.
======= Конец цитаты из файла FidoURL.txt =======
Ceterum censeo Diptaunum esse delendam! [Ru.Mozilla] http://Mithgol.Ru/
Mithgol the Webmaster. [Team В эхолисте ,,ё`` уместим] [Team А я меняю subj]
... Ибо выбор становится вечной тюрьмой, и предательством стал бы побег.
Так было 00:47 02 Feb 07 написано от Gennadiy Isayenko к Alex Kocharin:
MtW>>> The octet 20 hexadecimal MUST always be encoded.
AK>> How can it be encoded? Практика "+" распространяется?
GI> Кодируется элементарно - "%20". "+" - ИМХО, внутренняя реализация скрипта,
GI> остальные понимать не обязаны. Так кодируется просто разделитель, которым
GI> может быть и пробел и что угодно другое.
Вынужден (из любви к справедливости) заметить, что твоё имхо основано на явном
незнании RFC 1630, в котором сказано:
======= Hачало цитаты из файла rfc1630.txt =======
Network Working Group T. Berners-Lee
Request for Comments: 1630 CERN
Category: Informational June 1994
Universal Resource Identifiers in WWW
A Unifying Syntax for the Expression of
Names and Addresses of Objects on the Network
as used in the World-Wide Web
[ /_*... и скип ... долгий, зловещий скип ...*_/ ]
QUERY STRINGS
The question mark ("?", ASCII 3F hex) is used to delimit the
boundary between the URI of a queryable object, and a set of words
used to express a query on that object. When this form is used,
the combined URI stands for the object which results from the
query being applied to the original object.
Within the query string, the plus sign is reserved as shorthand
notation for a space. Therefore, real plus signs must be encoded.
This method was used to make query URIs easier to pass in systems
which did not allow spaces.
======= Конец цитаты из файла rfc1630.txt =======
Hастойчиво рекомендую тебе скачать этот документ и внимательнейше с ним
ознакомиться. А также (просто интереса ради) и RFC 1808, и RFC 2397.
Ceterum censeo Diptaunum esse delendam! [Ru.Mozilla] http://Mithgol.Ru/
Mithgol the Webmaster. [Team В эхолисте ,,ё`` уместим] [Team А я меняю subj]
... Я не уверен в завтрашнем дне: какое оно будет, завтрашнее дно? (C) unknown