Archive for June, 2009

Comments and ratings

Wednesday, June 17th, 2009

We worked late into the night last night and hammered out the last of the bugs in our comments and ratings system. It seems to be working pretty good. This will hopefully be that base which we can build several more features, such as:

  • Search for highest rated
  • Search for easiest rated
  • Sort in your recipe box by ratings
  • etc.

We do plan to have a full discussion thread for recipes (as needed, and in the future) so the comments are meant to be short comments - 140 characters or less. This is not meant for general discussion. With that in mind you can only rate or comment on any recipe 1 time. Your rating and comment is easily changeable though, should you change your mind.

All that said we hope you enjoy the new feature and take advantage of it as new features to come will be based off of that.
mind.

Thanks

ManagingMeals.com

Jquery CharCounter

Thursday, June 4th, 2009

Update #1: I made a small performance change. Now instead of calling the counter 4 times for each keypress it only gets called once. This should help with speeding up typing and should mostly render the delay feature nearly useless. I haven’t fully tested on all browsers though so let me know if you find something. When i’m finished building my feature I will begin testing on all browsers. If i find anythign then I will post again.

Tom Deater from http://www.tomdeater.com/jquery/character_counter/ wrote a nice little plugin for jquery to count the characters of a textbox and limit it to a certain count. Obviously this is just a front end check and a check should also be performed on the back end. In any case his plugin did just about everything we needed it to, here is a quick run down of what he had:

  • handles mouse paste/cut
  • handles ctrl+ cut and paste
  • handles text as typing
  • an optional delay for use with large complex pages
  • flashing output div
  • appends span if container not specified
  • configurable output

This was about everything we needed, except we prefer that if you hit your max character count then any keypress should be canceled. This makes it so that a character never shows up and then is quickly removed, as was the case. There are exceptions, you still need to be able to delete characters and use your basic ctrl shortcuts. So we made a small mod, here are the changes:

  • List of keys (or key combination’s) that work after max char hit
    • ctrl+a
    • ctrl+z
    • ctrl+x
    • ctrl+c
    • left arrow
    • right arrow
    • up arrow
    • down arrow
    • delete
    • backspace
  • All other keys are canceled when character count is reached

So that’s basically it.

You can sign up for our website and comment on a recipe (i’m still developing it so depending on when you read this you may not see the option to) to see a demo.

Click here to download it.

To find out more details or to use a demo without signing up for our site (our site is free by the way, and we have lots of other jquery and jquery ui implementations) you can check out the original sites link. It behaves nearly identical to that.