Re: Package(s) proposal(s): HTML_Image and HTML_Link.
| From: | Leandro Lucarella | Date: | Sun, 03 Aug 2003 16:35:09 +0000 |
| Subject: | Re: Package(s) proposal(s): HTML_Image and HTML_Link. | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-19184@lists.php.net to get a copy of this message | ||
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Stephan Schmidt, el domingo 3 de agosto a las 10:38 me escribiste:
> Hi,
>
> > Just a wrapper arround <IMG>. When using HTML_Page,
> > HTML_Table and HTML_Xxx objects, I found annoying to write
> > HTML directly, that's why I've done HTML_Image.
> I think, you should include some more features, I could think at least
> of these:
> - The class should be able to get the image size and add it too the
> attributes.
I thought that, but it has no sense in doing that. The image has it own
size. Seting the size is only useful when you want a different size.
> - It should add the ALT text to the title attribute, as some browsers
> display this attribute.
This is wrong. ALT and TITLE are two different attributes. ALT is an
alternative text that would be displayed only if the browser can't show
the image (even when some browsers show it as a hint). Title is the
title of the image. A good example is in my example script, with the PHP
Logo. In a text browser I want the image to be replaced for the text
"PHP Logo", but the TITLE of the image is "Welcome to the HTML_Image
example" (maybe it would has more sense if it says something like "PHP
Hypertext Preprocessor").
> - It should support the generation of image maps.
That would be nice. I don't know much about maps but it could be a
future feature.
> > Just a wrapper arround <A href="...">. It has one little
> > feature: GET variables "management". You can add get
> > variables to the link and they are automaticly urlencoded().
> > You can use an object with toString() method as a variable value.
> Again I'd like to see more features. Like:
> - Possibility to add a fragment to the link, maybe even user and pass,
> scheme, and so on
"fragment"? I don't understand.
> - Possibility to create anchors by supplying a name attribute.
Well. An Anchor is not a link, I think anchor should be a different
class or I'll change the name of the class to HTML_Anchor, but I don't
like that since an anchor and a link are two different things (it has no
sense on adding GET variables to an anchor, AFAIK).
- --
LUCA - Leandro Lucarella - Usando Debian GNU/Linux Sid - GNU Generation
- ------------------------------------------------------------------------
E-Mail / JID: luca@lugmen.org.ar
GPG Fingerprint: D9E1 4545 0F4B 7928 E82C 375D 4B02 0FE0 B08B 4FB2
GPG Key: gpg --keyserver pks.lugli.org.ar --recv-keys B08B4FB2
- ------------------------------------------------------------------------
* Knghtbrd notes he has mashed potatoes for brains tonight
<Valkyrie> yum, can I have some?
<Knghtbrd> um ...
* Knghtbrd hides from Valkyrie
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)
iD8DBQE/LTm9SwIP4LCLT7IRAlTlAJ9VLfbebJ80DcPxRslisLSpAS+1oQCdEBwA
SeCbUZ/4pOzG9sfvhiQpz/w=
=o+Eb
-----END PGP SIGNATURE-----