search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

I don't see the event on the calendar but it is present on DB

Related article: AngularJS Scheduler Tutorial
Asked by Gianluca
11 days ago.

Good morning

I was testing one of your AngularJS Scheduler products for possible uses on my application.... it works with an insertion that I find on the database but it does not let me view it on the web page. I performed the test on a windows server 2022 with php 8.3.3.

Thanks.

Answer posted by Dan Letecky [DayPilot]
11 days ago.

This tutorial was created for an older version of PHP.

PHP 8.3 produces warnings about using dynamic properties:

Deprecated: Creation of dynamic property ... is deprecated in ... on line ...

That disrupts the JSON output. You will see this warning in HTTP response if you check the Network tab in browser developer tools.

To fix this issue, you need to review the PHP scripts that produce this warning and modify the class definitions to include the properties.

Before:

class Event {}

After:

class Event {
  public $id;
  public $text;
  public $start;
  public $end;
  public $resource;
}
Comment posted by Gianluca
11 days ago.

Thanks for the quick reply, I imagined that the problem could be that I had already modified the php pages with the same instructions as you but it doesn't work the same. I will look for some other product. Good work.

Comment posted by Dan Letecky [DayPilot]
11 days ago.

Thanks for the update.

AngularJS is no longer supported and we don’t update the old AngularJS tutorials.

You may want to try one of the following up-to-date tutorials which both support PHP 8.3:

Comment posted by Gianluca
11 days ago.

Thanks yes I tried HTML5 Scheduler but I have the same problem...

Comment posted by Dan Letecky [DayPilot]
11 days ago.

Sorry to hear that. This tutorial was tested with PHP 8.3 so something else is going on. Could you please check the following:

  1. Do you use MySQL or SQLite?

  2. If you check the backend_events.php request in the developer tools, Network tab, do you see any error message in the response?

Comment posted by Dan Letecky [DayPilot]
11 days ago.

Also, does this problem affect all events (no event appears when loading the page) or just the new ones created using the UI?

Comment posted by Gianluca
11 days ago.

I use MySQL I create the event from the interface it seems that everything is ok ... I reload the page and it disappears, from debug I have no error messages

Comment posted by Gianluca
11 days ago.

sorry I forgot the pictures

Comment posted by Dan Letecky [DayPilot]
11 days ago.

OK, thanks!

There turned out to be a problem with the events.resource_id field type in MySQL - it was varchar instead of integer and the Scheduler didn’t match 1 with "1" properly. Previous versions of PHP returned string value in JSON in both cases.

Could you please give it a try with the updated download from the HTML5 Scheduler tutorial (just delete the database and let the app re-create it).

Comment posted by Gianluca
11 days ago.

this is the version i downloaded... php-html5-scheduler.20240622 deleted everything... and reconfigured everything, the problem is always the same....

Comment posted by Dan Letecky [DayPilot]
11 days ago.

There should be a new version labeled php-html5-scheduler.20241122.zip. Could you please give it a try?

Comment posted by Gianluca
8 days ago.

Good morning actually I saw that you have published a new version... this one works fine. Now I will test your product and see if I can customize it for my needs. thanks great work.

Comment posted by Dan Letecky [DayPilot]
8 days ago.

Great, thanks for the update!

If you need anything, just let me know.

New Reply
This reply is
Attachments:
or drop files here
Your name (optional):