June 2, 2022 at 9:20 am (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121774
I am experimenting with binding a jqxChart to a MySQL Database using PHP, as explained here :
In data.php, I am able to print out the json content of $orders through :
However, data.php is not properly called in index.php so that my index.php page remains blank.
Do you know what I could be doing wrong ?
Thanks a lot for your time and patience.
June 2, 2022 at 10:30 am (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121776
- This topic was modified 1 year, 4 months ago by Kami.
What is the folder structure of your project?
If data.php and index.php are in different folders then you need to specify the correct url to data.php in index.php
Also, each browser has a Network tab where you can check if the file was found and what content it returned.
In Google Chrome it is opened with ctrl + shift + j -> Network
https://www.jqwidgets.comJune 2, 2022 at 12:15 pm (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121779
thanks for your answer.
data.php and index.php are in the same folder.
(I have not modified the original files structure after having registered and downloaded all your demo examples.)
Firefox network tab shows me that all jQuery .js and .css files are correctly called except data.php .
Do you know where the problem could lie ?
K.June 2, 2022 at 12:58 pm (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121782
I tried the following URLs :
url: ‘data.php’ <!– as in your documentation –>
None of them worked.
Could you point me in the right direction ?
K.June 3, 2022 at 12:00 pm (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121790
When you said that index.php remains blank, can you please specify if really the whole index.php remains blank or just the chart is empty?
If the whole page is blank, this means that not all scripts are loaded correctly and the problem is not in data.php. You can try changing the url of the script files like so:
If there is an empty chart, this means that the problem is in data.php. When you open the Network tab, what code do you receive for data.php? Is it 404(not found) or 200(OK)? If it is 200, what is the exact content of the file?(you can check that by clicking the file -> Response)
June 3, 2022 at 1:55 pm (NEWBIE) PHP : Binding jqxChart to MySQL Database – Accessing data.php content #121792
- This reply was modified 1 year, 3 months ago by ivanpeevski.
Thanks for your help, the extra forward slash was missing.
(I am going to properly rearrange my files/folders structure in the future, just after I am done testing jqwidgets as a whole.)
You must be logged in to reply to this topic.