I'm facing a challenge when trying to activate a Drupal rule using JavaScript code.
lowerLayer[image.feature_nid].on("dragend", function() {
var position = kineticImage.getPosition();
var layerPosition = this.getPosition();
var slotNid = kineticImage.slot_nid;
positionX = position.x + layerPosition.x;
positionY = position.y + layerPosition.y;
//Here is where I want to trigger the Drupal rule
});
I have indicated the line where I require the Drupal rule to be triggered. Is it possible to invoke a Drupal rule with these parameters (slotNid,positionX,positionY) similar to calling a function (someFunction(slotNid,positionX,positionY)?
If you have any solutions or suggestions, please feel free to share them. Thank you.