This is what I've come up with so far but I might need to use the other ID's you listed above and am still testing things out...
function zen_update_whos_online() {
global $db;
if (isset($_SESSION['customer_id']) && $_SESSION['customer_id']) {
$wo_customer_id = $_SESSION['customer_id'];
$customer_query = "select customers.customers_firstname, customers.customers_lastname, address_book.entry_company
from customers
inner join address_book on customers.customers_id = address_book.customers_id
where customers.customers_id = '" . (int)$_SESSION['customer_id'] . "'";
$customer = $db->Execute($customer_query);
$wo_full_name = $customer->fields['entry_company'] . ', ' . $customer->fields['customers_firstname'] . ' ' . $customer->fields['customers_lastname'];
One issue I've run into is the output line looks as follows on the who's online screen from the admin view:
Company Name, First Last names
The issue is it can get rather long with some company and user names and I've tired to insert a /n for new line withough any luck as yet so the company will be on the first line then first/second name will be on the second line below the company name....
Thanks for your help and suggestions so far hope this might help someone else in the future but still open to idea's and advice on the above code and if it might have any impact on any other items on the website I have not through as well as well as idea's on the other items mentioned above.