By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,334 Members | 1,861 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,334 IT Pros & Developers. It's quick & easy.

% in ENTITY declaration

P: n/a
Could someone explain to me what is the difference between

<!ENTITY % Foo 'Bar' >

and

<!ENTITY Foo 'Bar' >

From my understanding, the "macro" Foo has to be referenced in
the first case by %Foo; and in the second case by &Foo; , but
I don't believe that this is the sole purpose of the '%' in
the former declaration.

Ronald
Jul 20 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a

"Ronald Fischer" <ro*****@eml.cc> wrote in message
news:21*************************@posting.google.co m...
Could someone explain to me what is the difference between

<!ENTITY % Foo 'Bar' >

and

<!ENTITY Foo 'Bar' >


1st one is parameter entity and is used within DTD i.e.

<!DOCTYPE rootnode [
<!ENTITY % HTMLlat1 SYSTEM "xhtml-lat1.ent">
%HTMLlat1;
]>

includes the contents of xhtml-lat1.ent (entity declarations mainly)
into DTD. Outside DTD %HTMLlat1; is just ordinary text and won't be
expanded.
see for example http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
for more parameter entity usage, also use google.

2nd is normal internal entity that should appear within element content and
attributes.
i.e. <TAG ATT="&Foo;">&Foo;</TAG>

Toni Uusitalo

Jul 20 '05 #2

P: n/a
"Toni Uusitalo" <to*******************@luukkudot.com> wrote in message news:<e2*****************@reader1.news.jippii.net> ...
see for example http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd


Thanks a lot.

BTW, are you aware that the From: address in your header is invalid?
Mail sent to it bounces with

550 5.1.2 <to*******************@luukkudot.com>... Host unknown (Name
server: luukkudot.com: host not found)

Ronald
Jul 20 '05 #3

P: n/a

"Ronald Fischer" <ro*****@eml.cc> wrote in message
news:21************************@posting.google.com ...
"Toni Uusitalo" <to*******************@luukkudot.com> wrote in message

news:<e2*****************@reader1.news.jippii.net> ...
see for example http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd


Thanks a lot.

BTW, are you aware that the From: address in your header is invalid?
Mail sent to it bounces with

550 5.1.2 <to*******************@luukkudot.com>... Host unknown (Name
server: luukkudot.com: host not found)


Yes! I'm aware of that! You should make some funny typos for your address
too,
haven't you heard a story about horrible spammers that drink your blood and
fill
your mailbox with evil filth in return ;-)

Cheers,
Toni Uusitalo
Jul 20 '05 #4

P: n/a
"Toni Uusitalo" <to*******************@luukkudot.com> wrote in message news:<zy****************@reader1.news.jippii.net>. ..
"Ronald Fischer" <ro*****@eml.cc> wrote in message
news:21************************@posting.google.com ...
BTW, are you aware that the From: address in your header is invalid?
Mail sent to it bounces with

Yes! I'm aware of that! You should make some funny typos for your address
too,
haven't you heard a story about horrible spammers that drink your blood and
fill
your mailbox with evil filth in return ;-)


For sure, yes, but I believe there are better ways to achieve the goal:
Note that practically *all* address harvesters access only the From:
address of the messages, so one possibility is to use a From: address
which is invalid in an obvious way, and put your true return address
in a Reply-To: header. When posting using a Newsreader, I use this approach.
It is important that you write the invalid From: address in a way that
it does not increase the load on the Net, if spammers try to send spam
to this address. You typically do this by using an invalid TLD. In your
case, you could use to**@suomi.invalid

When I have, for whatever reason, to use Google (or a similar service, which
does not allow me to use an invalid From: address), I use a free mail
account created just for that purpose. In my case, I use an account at
http://fastmail.fm/ , because this Web based mail reader is fast and
allows me to quickly erase all the spam. Note that I don't expect people
to answer by email anyway, so it does not harm that I clean up my fastmail
account only once a month or so.

If OTOH I would expect to get responses by email, I would say so in my
signature line. So far, I have never detected a case where I received spam
from posting my real address in a signature (or in the Reply-To: header),
but if you are really paranoid about this, you could post the address of
a mail forwarding service, which simply forwards to your real account, and
if you really start receiving spam, it is easy to use a new forwarder and
set up a suitable autoresponder on the old one.

Ronald
Jul 20 '05 #5

P: n/a
"Toni Uusitalo" <to**************@luukkudot.kom> wrote in message news:<ko*****************@reader1.news.jippii.net> ...
Ok. Thanks for the tips Ronald. My new From address should be better now and
doesn't
increase the net load?


That's correct (though I, personally, would use a TLD which is more
easily visible to be illegal than "kom" is ... for example, "illegal"
or "bogus" or "eat_slugs_you_spammer" would probably be a better
choice).

The problem with your *present* posting is not the From address
anymore, but that you use the fake From address also in the
Reply-To: header, and this is a bad idea. Remember
that Reply-To: headers are nearly never harvested, so you should
put there a valid address (though not necessarily your "primary"
address).

Ronald
Jul 20 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.