ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Add channel entry via cURL or such?

January 13, 2012 12:15pm

Subscribe [2]
  • #1 / Jan 13, 2012 12:15pm

    Hue Labs

    31 posts

    I’ve integrated with a 3rd party payment processing API. Once I get back a payment success message, I’d like to add an entry to a channel with the confirmation number and such.

    I’m using PHP and the SOAP client to get back the confirmation details. However, I’m not entirely sure how I can get these details into an Expression Engine channel. It sounds like I would need to use Safecracker, but I just need to submit the details, not build a form.

    Any help is greatly appreciated!

  • #2 / Jan 14, 2012 4:47pm

    Dan Decker

    7338 posts

    Hi Hue Labs,

    What format is the data being returned to you in? JSON, XML? There are several add-ons that can intercept incoming data and make entries based on that. If you give me a little more context I can get you headed in the right direction.

    Thanks!

  • #3 / Jan 14, 2012 10:28pm

    Hue Labs

    31 posts

    Thanks Dan.

    I’m collecting form information and calling a processing page (basically an EE template with some PHP and SOAP) via AJAX. I’m doing all the processing in the EE template and sending back an XML response. However, before I send the XML response back to the AJAX call, I’d like log the confirmation details into a channel.

    I’m just not sure how to manually add a channel entry without using Safecracker.

  • #4 / Jan 20, 2012 5:11pm

    Dan Decker

    7338 posts

    Hi Hue Labs,

    I am sorry for the delay in responding to you.

    Outside of SafeCracker, you can use the Channel API, which is accessible via PHP in templates.

  • #5 / Jan 20, 2012 8:15pm

    Hue Labs

    31 posts

    This was just what I was looking for, but somehow could not find. Many thanks Dan!

  • #6 / Jan 26, 2012 8:40pm

    Sean C. Smith

    3818 posts

    Hue Labs,

    Glad to see that Dan was able to help you out. I’m going to close out this thread, but feel free to post again when you have more questions.

    Sean

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases