0

I'm refreshing a div on menu selection -it reloads a php include. The issue - the php include has a script that is submitting a GET request to JSON in some data from yet another form.

the headers show it is sending the proper headers to the first form, the second form is a user input behind

Header results:

MIME Type: application/x-www-form-urlencoded; charset=UTF-8
location: 1

the chained file is getting this:
calDemo/data/api.php?location=

If I use the select menu again I get this result:

MIME Type: application/x-www-form-urlencoded; charset=UTF-8
location: 5

And

calDemo/data/api.php?location=1

next would be 
location: 3
calDemo/data/api.php?location=5

if I continue to increment the menu, they are always one input off. The data in the div reloads and shows me the content, it's just from the selection before the currently selected.

    $('#locationID').change(function(event) {
        $.post('calDemo/miniCal.php', { location: $('#locationID').val() },
        function(data) {
                $('#scheduleReload').html(data);
                    }
                );            
            });

and

       scheduler.load("calDemo/data/api.php?location=<? echo $location ?>");

        var dp = new dataProcessor("calDemo/data/api.php?location=<? echo $location ?>");
        dp.init(scheduler);
        dp.setTransactionMode("JSON"); 
  • Needs a debugging strategy. Firstly, is the problem client-side or server-side? You need to run tests. – Roamer-1888 Mar 14 '20 at 00:00
  • I agree with @Roamer-1888, unfortunately, there is no enough information to provide with a reply on how to solve the issue. Please either do it here or contact our DHTMLX team on forum/via support. – Polina Apr 02 '20 at 11:36

0 Answers0