0

How can I create a function / constructor (not sure how to call it) that is integrated with Jquery selector.

For example:

$('some selector').myFunction();

Where 'some selector' is any normal selector, and myFunction is a function that runs on these elements.

6

1 Answer 1

1

This is a jQuery plugin. Thyere is a simple tutorial on the jQuery site at http://learn.jquery.com/plugins/basic-plugin-creation/.

Sign up to request clarification or add additional context in comments.

1 Comment

Aaaah Plugin! That's the word I was suppose to be looking for! This should do it. thanks.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.