Someone built a site using joomla and third party plugin RS Forms Pro and created a page where a client could configure and purchase a product (via stripe). But they have asked me to write some scripts that allows them to create a basket system so clients can buy multiple products at once without entering their card details each time.
I have years of php/js experience but have never worked with a system like joomla. RSForms Pro allows me to attach javascripts and attributes to form items so this looked very easy and the JS part has indeed been simple. However, I wrote a small PHP shopping cart designed to be interfaced via GET url params and there is no where on the webserver I can place it where attempting an ajax request does not cause a 403 forbidden error.
What is the path of least resistance is to get the php api I've written into the joomla ecosystem in a way that will allow me to talk with it properly from within RSForms pages? Many thanks.
EDIT for functional details: The php script I wrote stores item data (class objects in this case) in a php session, it's essentially a simple session cart. The script itself expects to find instructions passed via URL, such as script.php?additem&itemdata=foobar which the script reads from the standard $_GET array. The script echo's a result which can either be some requested data, a confirmation or an error string - in all cases designed to be processed by the calling javascript.