We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44154
    • 6 Posts
    Hey guys,
    i'm trying to modify the EventX-plugin so, that i can add a time to the date. I already successfully changed the database-schema, the CMP (for the extra fields for the time), the problem now is that, if i submit the data, it doesn't get inserted into the database, instead of for example 2013-06-17 05:00:00, only 2013-05-17 00:00:00 gets written into the database.

    The CMP posts the data to modx/assets/components/eventsx/connector.php, with the following parameters:

    action mgr/event/update
    active 1
    city Testcity
    country Testcountry
    description description
    enddate 2013-06-17 06:00:00
    id 2
    introtext testtext
    location testlocation
    name kjgjhg
    pc
    region testregion
    startdate 2013-06-17 05:00:00
    street teststreet
    website www.test.de

    The answer, that gets returned is
    {"success":true,"message":"","total":0,"data":[],"object":{"id":2,"active":1,"name":"kjgjhg","introtext":"testtext","startdate":"2013-06-17","enddate":"2013-06-17","location":"testlocation","street":"teststreet","pc":"","city":"Testcity ","region":"testregion","country":"Testcountry","website":"www.test.de","action":"mgr\/event\/update"}}

    So i guess, the time gets lost somewhere in between. Most obviously somewhere in the update.php, but i have no idea how to change that.

    I hope you guys can help me with that problem, since i have no much knowlegde about the whole ModX-API.

    Regards
      • 44154
      • 6 Posts
      Can nobody help me?