Osclass forums

Support forums => General help => 3.6.x => Topic started by: hichamuser on December 05, 2016, 07:51:14 pm

Title: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 07:51:14 pm
hello everyone !
why my Locations stats calculate stay in 0% ?
where this bug coming please
php config ?
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 05, 2016, 08:20:07 pm
How many locations do you have (countries) ?

What is your hosting plan PHP physical memory allowance ?

Enable osclass debug to a log to see any errors.

https://doc.osclass.org/Debug_PHP_errors
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 08:55:56 pm
thank you bro
2 countries
PHP physical memory  up to 512 MB
debug.log actived
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 05, 2016, 09:14:05 pm
oK, 512 you have but are they available (activated) ?

If 512 are ok and 2 countries are also nothing big (i have 27), so you have some other problem. If debug.log is also clear, then it is not normal.

What kind of plan for hosting is that ? Shared ? VPS ? Linux i guess (because some use Windows .....) ...

Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 09:33:19 pm
can i write directly to you ? you have facebook bro
yes it's actived
 shared hosting bro
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 05, 2016, 09:50:13 pm
If it is shared i highly doubt you have 512 available.

Sorry, all i can help is here, so others can read and profit from possible solutions in the future.

Use this:

https://market.osclass.org/plugins/miscellaneous/php-info_82

and let us know of the memory available and other stuff (remove your domain if you want).
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 09:59:42 pm
i find this error in my debug.log
[05-Dec-2016 18:35:15 UTC] PHP Warning:  session_start(): Cannot send session cache limiter - headers already sent in /srv/disk9/2251493/www/Domain.com/oc-includes/osclass/core/Session.php on line 47

about my hosting plan look at my php.ini
log_errors_max_len = 1024
ignore_repeated_errors = Off
ignore_repeated_source = Off

report_memleaks = On
track_errors = Off

;error_prepend_string = ""

variables_order = "EGPCS"
;register_globals = On
register_argc_argv = On

post_max_size = 20M
memory_limit = 512M
gpc_order = "GPC"


magic_quotes_runtime = Off   
magic_quotes_sybase = Off
;auto_prepend_file = /var/www/index.php

;auto_append_file =

default_mimetype = "text/html"

doc_root =
user_dir =
enable_dl = On
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 05, 2016, 10:11:00 pm
Yeah, well it is probably a hosting problem. Try this:

Quote
Hi,

Looks like general /tmp temporary folder couldn't be used to store sessions, try inserting this line in your config.php (just before ?>):


session_save_path ( ABS_PATH . 'oc-content/uploads/' );

Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 05, 2016, 10:12:15 pm
Also not sure the above is a solution to your %0 problem but probably is for the debug (major) error.
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 10:30:13 pm
no result bro , i added code to my config.php
 bro look at my website http://www.3rbi.com/index.php?page=item&action=item_add
 try to select ( county , region , city ) the cities stay the same
can you help me bro to solve this bug
PS : when i installed the script v 3.6.1 and theme on another webhosting  all works perfectly
Title: Re: Locations stats 0 % Complete
Post by: teseo on December 05, 2016, 10:59:51 pm
Hi,

When you select a region there's an Ajax call to get the cities:

Quote
[{"pk_i_id":"425338","fk_i_region_id":"782046","s_name":"Acampo","fk_c_country_code":"us","b_active"
:"1","s_slug":"acampo"},{"pk_i_id":"425929","fk_i_region_id":"782046","s_name":"Acton","fk_c_country_code"
:"us","b_active":"1","s_slug":"acton"},{"pk_i_id":"426147","fk_i_region_id":"782046","s_name":"Adelanto"
,"fk_c_country_code":"us","b_active":"1","s_slug":"adelanto"},{"pk_i_id":"425655","fk_i_region_id":"782046"
,"s_name":"Adin","fk_c_country_code":"us","b_active":"1","s_slug":"adin"} etc

But your server is returning this response:

Quote
<br />
<b>Deprecated</b>:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in
 a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use
 the php://input stream instead. in <b>Unknown</b> on line <b>0</b><br />
[{"pk_i_id":"425338","fk_i_region_id":"782046","s_name":"Acampo","fk_c_country_code":"us","b_active"
:"1","s_slug":"acampo"},{"pk_i_id":"425929","fk_i_region_id":"782046","s_name":"Acton","fk_c_country_code"
:"us","b_active":"1","s_slug":"acton"},{"pk_i_id":"426147","fk_i_region_id":"782046","s_name":"Adelanto"
,"fk_c_country_code":"us","b_active":"1","s_slug":"adelanto"},{"pk_i_id":"425655","fk_i_region_id":"782046"
,"s_name":"Adin","fk_c_country_code":"us","b_active":"1","s_slug":"adin"}

So seems that you'd need the change that value in php.ini, always_populate_raw_post_data = -1

Regards
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 11:13:53 pm
so i change always_populate_raw_post_data =
to
always_populate_raw_post_data = -1 ?
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 05, 2016, 11:40:56 pm
thank youuuu bro you're the best
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 12:25:17 am
@teseo What is depreciated ? I don't get it ? Is something of Osclass ? Is the guy running an old PHP (5.3 ?) ?

Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 12:32:26 am

PS : when i installed the script v 3.6.1 and theme on another webhosting  all works perfectly

Well, goddady is nothing to write home about ....
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 02:02:50 am
hihi i tried to delete country  the website redirected me to installation link
so i will restart from 0  :-X
but the problem is solved thank you
bro ! what about CHMOD i need to give after installation?
i'am not on goddady bro
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 02:12:31 am
yeap! My mistake, i saw godaddy as registar and messed it up.

But all those seem like a bad selection of host.

Good luck.

* the permissions should be set automatically by you hoster BUT since they seem not to know how to set all correctly, the Folders should be 755 and the files 644. No more no less :)
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 03:03:03 am
bro why when i try to change anything in my admin panel the website redirect me to the installation page  :-X :-X
please help
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 03:14:22 am
Maybe your Osclass config.php has a wrong url/path (last two options) ?

Or the database is not set up. I can't really say.
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 03:19:45 am
my config.php


<?php

/**
 * The base MySQL settings of Osclass
 */
define('MULTISITE', 0);

/** MySQL database name for Osclass */
define('DB_NAME', 'xxxxxxxxxx');

/** MySQL database username */
define('DB_USER', 'xxxxxxx');

/** MySQL database password */
define('DB_PASSWORD', 'xxxxxxxxxx');

/** MySQL hostname */
define('DB_HOST', 'xxxxx');

/** Database Table prefix */
define('DB_TABLE_PREFIX', 'oc_');

define('REL_WEB_URL', '/');

define('WEB_PATH', 'http://www.xxxxxxx.com/');

?>
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 01:30:40 pm
my config.php


define('REL_WEB_URL', '/');

define('WEB_PATH', 'http://www.xxxxxxx.com/');

?>

Seems right.
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 02:52:30 pm
i think this big trouble coming when we try to unistall location ,
installed from te first installation
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 02:56:00 pm
i think this big trouble coming when we try to unistall location ,
installed from te first installation

My friendly advice, find a proper web hosting company. Don't spend any more time with all that.
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 07:21:52 pm
bro give me link of this company
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 07:29:19 pm
bro give me link of this company

You mean to suggest one ? I can only vote for the one i use for a long time (and others here):

www.mddhosting.com

Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 08:07:33 pm
ok bro thank you so much
i use https://www.awardspace.com   basic plan , now
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 06, 2016, 08:29:06 pm
ok bro thank you so much
i use https://www.awardspace.com   basic plan , now

Well what do you expect for so low price for hosting ? Osclass is a demanding script, you must use something better.
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 06, 2016, 08:34:50 pm
i dont know bro its my first experience with them
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 07, 2016, 05:40:38 pm
i can't install the script
the error massege :
Can't insert basic configuration. Error number: 1036

what's the solution please
Title: Re: Locations stats 0 % Complete
Post by: Aficionado on December 07, 2016, 06:04:45 pm
The solution is 2 posts above.

Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 07, 2016, 06:13:38 pm
 i'am on another shared hosting bro  :-[
Title: Re: Locations stats 0 % Complete
Post by: teseo on December 07, 2016, 09:07:55 pm
But your server is returning this response:

Quote
<br />
<b>Deprecated</b>:  Automatically populating $HTTP_RAW_POST_DATA is deprecated and will be removed in
 a future version. To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini and use
 the php://input stream instead. in <b>Unknown</b> on line <b>0</b><br />
[{"pk_i_id":"425338","fk_i_region_id":"782046","s_name":"Acampo","fk_c_country_code":"us","b_active"
:"1","s_slug":"acampo"},{"pk_i_id":"425929","fk_i_region_id":"782046","s_name":"Acton","fk_c_country_code"
:"us","b_active":"1","s_slug":"acton"},{"pk_i_id":"426147","fk_i_region_id":"782046","s_name":"Adelanto"
,"fk_c_country_code":"us","b_active":"1","s_slug":"adelanto"},{"pk_i_id":"425655","fk_i_region_id":"782046"
,"s_name":"Adin","fk_c_country_code":"us","b_active":"1","s_slug":"adin"}

@teseo What is depreciated ? I don't get it ? Is something of Osclass ? Is the guy running an old PHP (5.3 ?) ?

@aficionado:

http://stackoverflow.com/questions/26261001/warning-about-http-raw-post-data-being-deprecated

Looks like a problem of PHP 5.6 ???

Regards
Title: Re: Locations stats 0 % Complete
Post by: hichamuser on December 07, 2016, 09:15:36 pm
teseo bro i solved that problem and wibsite work fine
look : To avoid this warning set 'always_populate_raw_post_data' to '-1' in php.ini .

i'am working on another website .