Monday, August 16, 2010

Funny behavior of my IE

When I run a php script that contains a javascript script that sorts a table, it worked fine for quite sometime till I added a `part description` field. Now it seems like certain data cannot be shown without the `IE timeout due to script take longer than usual` error. After I accepted the termination of the script, the sorting script no longer runs.

Funny thing is that this issue only appears on my IE. I tried on at leat 3 other IE on other machines and they all shows the table without error. What in the world happened?

Since it is system generated error and that I know it was caused by the data in `part description` field, I decided not to `repair` my IE but concentrate on making the field workable with the javascript.

Well, it is quite simple. I simply remove any character that is not allowed by me using preg_replace command. It cut short all the necessity to replace any character that caused the javascript error. The regexp code is [^a-zA-Z0-9\\-\\.,\\/_ &:;] with a `si` parameter.

Obviously, I did not solve my IE problem. But who cares when it does not complain anymore.

No comments:

Post a Comment