RSS Feed/News Returning results in new API endpoint

Status
Not open for further replies.

ENXF NET

Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
Joined
Nov 13, 2018
Messages
24,714
Points
823

Reputation:

Hello,
I've added a new API endpoint to an addon we use (Snogs Advanced forms).
It seems to fetch the items (forms) but the api result returns an array of objects sorted alphabetically.
The code for returning the data is:
PHP:

Code:
return $this->apiResult([
    'forms' => $forms->toApiResults(),
    'pagination' => $this->getPaginationData($forms, $page, $perPage, $total)
]);

The JSON example:

JSON:

Code:
{
    "posid": 1,
    "z_connectedThread": 0,
    "z_description": "testing form"...

Read more

Continue reading...
 
Status
Not open for further replies.
Top