js for 1 serie server (not finished)