What’s new?

jQuery Calx version 2.0 is the successor of jQuery Calx 1.x. It offer a lot of new feature since version 1.x, let see what’s new in jQuery Calx 2.0

  • Rewrite the internal formula parser and plugin structure.
  • Ability to register new function and override default one.
  • Ability to register variable.
  • Easy graph to represent data in graphical way (additional library required)
  • Add support for string and cell range.
  • Add a lot of excel compatible function (additional library may be required).
  • Add feature to check circular reference, instead of infinite loop which make the page hang up, it’s now alerting error.
  • Add support for server-side function formula, in case you want to hide the calculation algorithm.
  • Add support to change formula, value, format easily without need to write tricky script.

To support us developing more feature on jQuery Calx 2.x, you can fork and send a pull request on the github repository https://github.com/xsanisty/jquery-calx or you can send a donation to us.

Updating from 1.x

If you are using jQuery Calx 1.x and want to update to 2.x, here is some points you need to take care of.

Replace id with data-cell for cell addressing

jQuery Calx 2.x use data-cell attribute to set the cell-address, since there are possibility of two or more same cell-address in single page

<!-- previous -->
<input id="A1" />

<!-- current -->
<input data-cell="A1" />

No more $ sign in formula

In jQuery Calx 1.x, we use $A1 to get the value of cell with address A1, in 2.x we completely remove the $ sign and use the cell address directly to access it’s value

<!-- previous -->
<input data-formula="SUM($A1,$B10)" />
<input data-formua="$D8-$D5" />

<!-- current -->
<input data-formula="SUM(A1:B10)" />
<input data-formula="D8-D5" />