Archive for the ‘ Frontend Tech ’ Category

CSS Trick : text-overflow

I’d like to share with a css trick that I recently discovered accidently.
It’s called “text-overflow”. How many times have you created and used a script that truncate overflown statement and add “…” to the end of it?

But IE has css property, text-overflow, and it will make your life lot easier.

Here’s an example:

President Bush said for the first time on Thursday he made a “miscalculation of what the conditions would be” after U.S. troops went to Iraq.
President Bush said for the first time on Thursday he made a “miscalculation of what the conditions would be” after U.S. troops went to Iraq.

See how beautifully it truncated!

Note: you should be using <nobr> in order for text-overflow to work.

ECMAScript for XML

Also check this out too.

What I like this about is that it can access and modify xml elements, attributes, and nodes directly just like FlashVar class does.

Anyways, it’s Standard ECMA-357 and its specification is at the link

But isn’t this re-inventing another wheel? We already have xpath which does very similar things that they suggested. And also xpath has come close to version 2.0 and it’s considered and called *standard*. Why ECMA Internation organization accepts standard xpath and implement it into ecma scripting language for the sake of standard??

Or is xpath considered to be an core part of ECMA-357 and is it just a way to change how we write and use XML in ECMAScript language?

How to cover an IE windowed control (Select Box, ActiveX Object, etc.) with a DHTML layer.

http://dotnetjunkies.com/WebLog/jking/archive/2003/07/21/488.aspx

It’s awesome tip for DHTML menu over form elements(select)

warning message when using window.close in javascript

When you want to close browser itself by javaScript, which is not opened by another browser window, you will be getting a warning message if you are on IE.

window.close();

However, if you do this window.opener = “whatever”; before calling window.close(), you won’t get a warning message.

That’s today’s tip!

Firefox’s RSS Reader

I have tried pluck with IE; however, I felt that this seems to slow down IE browsing a bit. So I was looking for an alternative for Firefox and found this one.

http://fls.moo.jp/moz/rssreader.html

With this you will manage your rss feeds as you do with bookmarks and it’s so incorporated with the browser.

DynAPI

I am pretty sure that many ppl are already using DynAPI from time to time. For the real web sites in the real world, compatibility is still the very important thing to consider and using DynAPI can help that compatibility issues solved.

It’s JavaScript DHTML Library which is of course cross-browser. I have used this once and it worked pretty nice. When you do not have time to build your own kind, DynAPI can come in handy.

http://dynapi.sourceforge.net/dynapi/