Jump to content
medvid

Who's Online Enhancement 1.4

Recommended Posts

missed a colon in the referrer url: Should be:

 

if($_SERVER['HTTP_REFERER'] != 'http://map.google.com/'.$_SERVER['QUERY_STRING']) header("Location: /");

Share this post


Link to post
Share on other sites

anyone experiencing EXTREMELY slow page load the first time the url is reached (idoes not happen after that, the refresh are fast...) I'm suspecting the connexion to api.ipinfodb.com?

 

There always has been a little delay compared to the "non-flag" version, but it became worse lets say... in 2013

 

Thank you for your input!

Share this post


Link to post
Share on other sites

I have installed the Who's online enhancement 3.6.7.2 and done the updates all the way up to update 231osc version. I cannot get the geolocations to display. The city, region, and referer are all blank. I also cannot get the map to come up. I got the Google Maps Api v3 key. The API Access link in my Google API console does have an exclamation mark by it. Not sure what that means and if that has anything to do with why the map won't come up. Is this something that I'm required to set up a credit card account with cause I see the Billing link below it?

Share this post


Link to post
Share on other sites

anyone experiencing EXTREMELY slow page load the first time the url is reached (idoes not happen after that, the refresh are fast...) I'm suspecting the connexion to api.ipinfodb.com?

 

There always has been a little delay compared to the "non-flag" version, but it became worse lets say... in 2013

 

Thank you for your input!

 

 

I also was dismayed by the slow load times.

Then I commented out the map calling function. (As detailed above) and its now almost instant.

 

The map is a gimic anyway.

Share this post


Link to post
Share on other sites

yahalimu

 

Removing the map calling did not improve anything on my end...

 

any suggestions?

Edited by pixclinic

Share this post


Link to post
Share on other sites

Hi everybody,

I have installed this contribution 2 years ago and for me it's the best usefully cont that I have in my os 2.2.

But today the cont just stop to work!! when I clik in the who's on line link the page doesn't appear and appear this message

Gateway Timeout

 

The gateway did not receive a timely response from the upstream server or application.

 

until yesterday everything was ok, I don't change anything, I really don't know what's happen.

Can someone help me?

thanks

Paolo

Share this post


Link to post
Share on other sites

Hi All of you out there my who is online has gone slow too, anyone founfd out what the problem is yet ?

Share this post


Link to post
Share on other sites

I keep getting the following error with Who's Online. It doesn't happen every time I go into Who's Online but it does most of the time. What could be causing this? This has been going on for quite awhile now and is getting very annoying.

 

Internal Server Error

 

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Share this post


Link to post
Share on other sites

I keep getting the following error with Who's Online. It doesn't happen every time I go into Who's Online but it does most of the time. What could be causing this? This has been going on for quite awhile now and is getting very annoying.

 

Internal Server Error

 

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator to inform of the time the error occurred and of anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

 

These are the errors I am getting in my error logs:

 

[sat Nov 30 03:43:33 2013] [warn] [client 173.233.120.142] mod_fcgid: read data timeout in 120 seconds, referer: http://sparklespot.com/catalog/admin_new/banner_manager.php

[sat Nov 30 03:43:33 2013] [warn] [client 173.233.120.142] (110)Connection timed out: mod_fcgid: ap_pass_brigade failed in handle_request_ipc function, referer: http://sparklespot.com/catalog/admin_new/banner_manager.php

 

The mod_fcgid: read data timeout was 45 but I went into /etc/httpd/conf.d/fcgid.conf and changed the FcgidlOTimeout to 120. It did not do any good though. I'm still getting the errors. What could be causing the Who's online to be timing out?

Share this post


Link to post
Share on other sites

For now I sorted this out by replacing whos_online.php file with the one from version 3.5.4

 

This worked for me for now. Any idea how to fix the latest version though?

Share this post


Link to post
Share on other sites

Hi, ipinfodb API changed again, for the lastest version to work you have to change a few things.

 

1- admin/includes/classes/ipinfodb.class.php change this:

 

line 6 from

var $version = 'v2';

to

var $version = 'v3';

 

line 30 from

$xml = 'http://' . $this->service . '/' . $this->version . '/' . 'ip_query.php?key=' . $this->apiKey . '&ip=' . $ip;

to

$xml = 'http://' . $this->service . '/' . $this->version . '/' . 'ip-city/?key=' . $this->apiKey . '&ip=' . $ip . "&format=xml";

 

2- admin/whos_online.php change this:

 

starting line 182 replace:

 

$country_code = mysql_real_escape_string($answer['CountryCode']);

$country_name = mysql_real_escape_string($answer['CountryName']);

$region_name = mysql_real_escape_string($answer['RegionName']);

$city = mysql_real_escape_string($answer['City']);

$latitude = mysql_real_escape_string($answer['Latitude']);

$longitude = mysql_real_escape_string($answer['Longitude']);

 

with:

 

$country_code = mysql_real_escape_string($answer['countryCode']);

$country_name = mysql_real_escape_string($answer['countryName']);

$region_name = mysql_real_escape_string($answer['regionName']);

$city = mysql_real_escape_string($answer['cityName']);

$latitude = mysql_real_escape_string($answer['latitude']);

$longitude = mysql_real_escape_string($answer['longitude']);

 

 

That's it and all should start working as normal.

Edited by Baltasar

Share this post


Link to post
Share on other sites

Hi, ipinfodb API changed again, for the lastest version to work you have to change a few things.

 

1- admin/includes/classes/ipinfodb.class.php change this:

 

line 6 from

var $version = 'v2';

to

var $version = 'v3';

 

line 30 from

$xml = 'http://' . $this->service . '/' . $this->version . '/' . 'ip_query.php?key=' . $this->apiKey . '&ip=' . $ip;

to

$xml = 'http://' . $this->service . '/' . $this->version . '/' . 'ip-city/?key=' . $this->apiKey . '&ip=' . $ip . "&format=xml";

 

2- admin/whos_online.php change this:

 

starting line 182 replace:

 

$country_code = mysql_real_escape_string($answer['CountryCode']);

$country_name = mysql_real_escape_string($answer['CountryName']);

$region_name = mysql_real_escape_string($answer['RegionName']);

$city = mysql_real_escape_string($answer['City']);

$latitude = mysql_real_escape_string($answer['Latitude']);

$longitude = mysql_real_escape_string($answer['Longitude']);

 

with:

 

$country_code = mysql_real_escape_string($answer['countryCode']);

$country_name = mysql_real_escape_string($answer['countryName']);

$region_name = mysql_real_escape_string($answer['regionName']);

$city = mysql_real_escape_string($answer['cityName']);

$latitude = mysql_real_escape_string($answer['latitude']);

$longitude = mysql_real_escape_string($answer['longitude']);

 

 

That's it and all should start working as normal.

 

 

 

This worked, but the country flag not appear more. Can you help me?

Share this post


Link to post
Share on other sites

I loved this addon, but how do I get it to work with OsCommerce V2.3.3 can someone PLEASE update it, it was such an awesome addon

Share this post


Link to post
Share on other sites

I loved this addon, but how do I get it to work with OsCommerce V2.3.3 can someone PLEASE update it, it was such an awesome addon

 

yes i want this contrib also :) P.S. i have oscommerce version 2.3.3 but in can not see what people have in their shoppingcart can sombody tell me what i need to do?

Share this post


Link to post
Share on other sites

I upgraded my shop to 2.3.3.4 from 2.2 and this addon cannot load (it seems there is infinite loop). Any idea how to fix it before I start to debug it?

Share this post


Link to post
Share on other sites

Hi there

 

Not a coder so can only state that what i have tried and seems to work, couldnt get a key from the google api so have just left it blank and do not get city information but not bothered about that

 

I have 2.3.4BS and have most of the functions working by installing 3.7.1  and then applied the update osc2.3.1 verisons of the add ons

 

Then there were sessions problems so I applied the following fix found at

http://library.oscommerce.com/Online&en&oscom_2_3&release_notes&v2_3_3_3

 

 

includes/functions/sessions.php

change tep_session_recreate() from:

function tep_session_recreate() {
  global $SID;

  if (PHP_VERSION >= 5.1) {
    session_regenerate_id(true);

    if (!empty($SID)) {
      $SID = tep_session_name() . '=' . tep_session_id();
    }
  }
}

To

function tep_session_recreate() {
  global $SID;

  if (PHP_VERSION >= 5.1) {
    $old_id = session_id();

    session_regenerate_id(true);

    if (!empty($SID)) {
      $SID = tep_session_name() . '=' . tep_session_id();
    }

    tep_whos_online_update_session_id($old_id, tep_session_id());
  }
}

and

 

includes/functions/whos_online.php

$stored_customer_query = tep_db_query("select count(*) as count from " . TABLE_WHOS_ONLINE . " where session_id = '" . tep_db_input($wo_session_id) . "'");
$stored_customer = tep_db_fetch_array($stored_customer_query);

if ($stored_customer['count'] > 0) {

to

$stored_customer_query = tep_db_query("select session_id from " . TABLE_WHOS_ONLINE . " where session_id = '" . tep_db_input($wo_session_id) . "' limit 1");

if ( tep_db_num_rows($stored_customer_query) > 0 ) {

after tep_update_whos_online(), add:

function tep_whos_online_update_session_id($old_id, $new_id) {
  tep_db_query("update " . TABLE_WHOS_ONLINE . " set session_id = '" . tep_db_input($new_id) . "' where session_id = '" . tep_db_input($old_id) . "'");
}

As I state not a coder, so please do not ask for more info, and if you try the above back up first

 

regards


David

Share this post


Link to post
Share on other sites

Hi All,

 

I need some help, I have os 2.3.4 running and installed this modification.

It shows the  customers online but generates these errors:

 

Warning: mysql_real_escape_string() [function.mysql-real-escape-string]: Access denied for user ''@'localhost' (using password: NO) in /home/....../httpdocs/admin/whos_online.php on line 182

Warning: mysql_real_escape_string() [function.mysql-real-escape-string]: A link to the server could not be established in /home/....../httpdocs/admin/whos_online.php on line 182

Warning: mysql_real_escape_string() [function.mysql-real-escape-string]: Access denied for user ''@'localhost' (using password: NO) in /home/...../admin/whos_online.php on line 183
.....

 

 

I have tested the key bij creating and entering the entire url in a brwoser and the site returns XML information. When i insert print statements in the ipinfodb.class.php file, it looks like the code stops after this line ( i have put a print behind this line and does not show).

 

$response = @@new SimpleXMLElement($xml);

 

 

 

Does any one have a idea what the cause could be???

 

 

Thanks in advance,

 

Fabien

Edited by Peace2u

Share this post


Link to post
Share on other sites

Hi, I have an issue with the addon on the admin side- It does not seem to load;

It keeps on showing Connecting....on the bar below the browser....

Any idea what the issue is... As I am not able to figure out the problem

I am using PHP 5.3 and oscommerce 2.3.4
Your help will be deeply appreciated

Share this post


Link to post
Share on other sites

Anyone have a suggestion on how to display the attributes in the admin page for whos_online.php? When you click on the customer it shows the shopping cart, but it doesn't include any product attribute information.

Share this post


Link to post
Share on other sites

Hello. When I click on the customer with shopping cart, it shows the product in the cart but Subtotal is shown as: "Subtotal 0". Is anybody else having the same issue?

Share this post


Link to post
Share on other sites

Hi there,

 
After updating oscommerce to version 2.3, the module who is online is not working any longer. I'm trying the installation of the module from scratch, but The SQL improt gives an error, can someone help me?

post-337883-0-56462200-1481558139_thumb.png

Share this post


Link to post
Share on other sites

@@lamie The error is happening because you are trying to alter something that has already been altered. If the new sql is not different than the old, then you can skip that step in the installation. The only way to know if it is different, assuming it doesn't mention it in the docs, is to look at the database and compare it to what you are trying to change. But you can go ahead and skip that step for now. If the database is missing something, you will get an error showing that when you try to use who's online.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×