jquery.torturial

An advanced jQuery tutorial plugin. Teach your users to use your web page.

View the Project on GitHub nmussy/jquery.torturial

My other projects

Examples

Here are a few torturials, to give the laziest of you a glimpse at how the plugin works.

First up, a quick view at what a view looks like when it's on its own:

It's most likely the ugliest jQuery plugin initialization you've ever seen, but it is designed to build bigger tutorials.

Here's a more complex example. It doesn't get any prettier, though.

You might want to bring back elements to the front of the page. It's very easy to do with a torturial, you just use a jQuery selector.
Be careful though: if the elements selected aren't the same that at the time of the initialization of the torturial, you'll have to manually bring them to the back using a changeOn event. You can check out methods.cleanStep() to see how to do so.

Let's go back to the change handlers. Your function will be wrapped around an actual handler, that destroys itself when it needs to.
It's actually pretty neat, if I do say so myself. That way, you can go crazy in your function without worrying about when to remove the handler.

The problem is, if you return before the end of your handler, the plugin's function won't know about it, and will jump to the next step.
That's why you need to return a false boolean if you want to stop the event's propagation.

The why of the project

I realize that it's a very specific thing, a website tutoring jQuery plugin. That's why I couldn't find a good one. So I took off my whining cap and put on my coding one. It's my first jQuery plugin, and GitHub project. I don't think a lot of people will actually use it, but it wasn't really the goal.

It's one of these very long-shot Google searches result that ends up saving you hours of work.
It's that plugin that your jQuery lover friend bet he could find on the Registry.
Another cute comparison to establish a rythm.

I do hope a few of you will end up using it, and I'd really appreciate any kind of feedback. You'll be able to find some contact info on my GitHub Profile.
A "ur gay" always goes a long way.