Skip to content
Advertisement

Tag: jquery

Generic way to detect if html form is edited

I have a tabbed html form. Upon navigating from one tab to the other, the current tab’s data is persisted (on the DB) even if there is no change to the data. I would like to make the persistence call only if the form is edited. The form can contain any kind of control. Dirtying the form need not be

Ellipsis in the middle of a text (Mac style)

I need to implement ellipsis (“…”) in the middle of a text within a resizable element. Here is what it might look like. So, becomes When the element is stretched out to the width of the text, I want the ellipsis to disappear. How can this be done? Answer In the HTML, put the full value in a custom data-*

How to check if element is visible after scrolling?

I’m loading elements via AJAX. Some of them are only visible if you scroll down the page. Is there any way I can know if an element is now in the visible part of the page? Answer This should do the trick: Simple Utility Function This will allow you to call a utility function that accepts the element you’re looking

Advertisement