as the title suggests, I am trying to get the firstname (or maybe the lastname and username also from the user name), so that I can add it to a custom query in order_history.
What I have made so far (maybe a little irrelevant from what I am asking):
in the file /catalog/model/checkout/order.php
Code: Select all
//line 345 aproximatly $name_for_added_by="admin"; $this->db->query("INSERT INTO " . DB_PREFIX . "order_history SET order_id = '" . (int)$order_id . "', order_status_id = '" . (int)$order_status_id . "', notify = '" . (int)$notify . "', added_by = '".$name_for_added_by."', comment = '" . $this->db->escape($comment) . "', date_added = NOW()");
Now what i am trying to do is set "$name_for_added_by" with the user that presses the button-history (to update the history);
What I found (from /admin/controller/common/header.php) is that I need "$user_info['firstname']". However I can not get something to work.
Any ideas? Thanx