{"action":"created","issue":{"url":"https://api.github.com/repos/woothemes/woocommerce/issues/8124","labels_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8124/labels{/name}","comments_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8124/comments","events_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8124/events","html_url":"https://github.com/woothemes/woocommerce/issues/8124","id":73717687,"number":8124,"title":"Issues with get_order_total();","user":{"login":"mikakaltoft","id":10320181,"avatar_url":"https://avatars.githubusercontent.com/u/10320181?v=3","gravatar_id":"","url":"https://api.github.com/users/mikakaltoft","html_url":"https://github.com/mikakaltoft","followers_url":"https://api.github.com/users/mikakaltoft/followers","following_url":"https://api.github.com/users/mikakaltoft/following{/other_user}","gists_url":"https://api.github.com/users/mikakaltoft/gists{/gist_id}","starred_url":"https://api.github.com/users/mikakaltoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikakaltoft/subscriptions","organizations_url":"https://api.github.com/users/mikakaltoft/orgs","repos_url":"https://api.github.com/users/mikakaltoft/repos","events_url":"https://api.github.com/users/mikakaltoft/events{/privacy}","received_events_url":"https://api.github.com/users/mikakaltoft/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":2,"created_at":"2015-05-06T19:44:41Z","updated_at":"2015-05-08T06:47:33Z","closed_at":"2015-05-06T20:53:52Z","body":"Hey,\r\n\r\nI have created a plugin and want to grap the total of the order with the code:\r\n\r\nadd_action( 'woocommerce_thankyou', 'rocapress_tracking_dev' );\r\nfunction rocapress_tracking_dev( $order_id ) {\r\n\r\n$order = wc_get_order( $order_id );\r\n\r\n$total = $order->get_order_total();\r\n\r\necho $total;\r\n\r\n}\r\n\r\nHowever, I get this error: Fatal error: Call to undefined method WC_Order::get_order_total() in .../wp-content/plugins/my-plugin/my-plugin.php on line 32\r\n\r\nCan you tell me why get_order_total() gives me that error? And how can I possible fix it?\r\n\r\nI believe that this could possible be a bug since I am using the latest version of WooCommerce and WordPress.\r\n\r\nSincerely,\r\nMika"},"comment":{"url":"https://api.github.com/repos/woothemes/woocommerce/issues/comments/100123614","html_url":"https://github.com/woothemes/woocommerce/issues/8124#issuecomment-100123614","issue_url":"https://api.github.com/repos/woothemes/woocommerce/issues/8124","id":100123614,"user":{"login":"mikakaltoft","id":10320181,"avatar_url":"https://avatars.githubusercontent.com/u/10320181?v=3","gravatar_id":"","url":"https://api.github.com/users/mikakaltoft","html_url":"https://github.com/mikakaltoft","followers_url":"https://api.github.com/users/mikakaltoft/followers","following_url":"https://api.github.com/users/mikakaltoft/following{/other_user}","gists_url":"https://api.github.com/users/mikakaltoft/gists{/gist_id}","starred_url":"https://api.github.com/users/mikakaltoft/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikakaltoft/subscriptions","organizations_url":"https://api.github.com/users/mikakaltoft/orgs","repos_url":"https://api.github.com/users/mikakaltoft/repos","events_url":"https://api.github.com/users/mikakaltoft/events{/privacy}","received_events_url":"https://api.github.com/users/mikakaltoft/received_events","type":"User","site_admin":false},"created_at":"2015-05-08T06:47:33Z","updated_at":"2015-05-08T06:47:33Z","body":"Yep, worked perfectly! Thanks!\r\n\r\nIs it possible that there isn't either a method I can call to get the shipping total?"}}