I'm interested in overriding
function uc_node_checkout_nodeapi(&$node, $op, $arg3 = NULL, $arg4 = NULL)

This ubercarts, node_checkout implementation of hook_nodeapi()

I'm trying to change the node_checkout_nid to a nid of my own. Essentially, I want to allow people to put their products in someone elses shopping cart.

I could hack this module, which I really don't want to do.

I have my own implementation of hook_nodeapi() in my module, but not sure how I would go about intercepting the UC values.

Any ideas?

Thanks!

Comments

nevets’s picture

Two thoughts

a) Make a module that also implements hook_nodeapi(). Though you can not override uc_node_checkout_nodeapi(), if your function runs after it, it can change the results.

b) My memory says ubercart has an api that may provide a more direct way for overriding the checkout process.

alekm’s picture

Thanks for your reply. Unfortunately I didn't seem to be able to hook into the function, I ended up hacking node_checkout (horrible I know!). I've isolated the module and will keep it specific to that one website.

Thanks for your help!