This one has been baffling me for a while and I still haven't found an answer yet hence why I'm asking on here.
I'm running a fresh install on Opencart 2.1.0.2 so I know it's not to do with any additional vqmods etc.
To cut a long story short I plan to have a UK & a Rest of World Shipping geozone.
If i setup a new Geozone & add all the countries listed to it (apart from the UK), then save, whenever i go back into the geozone to edit it it gives me a 500 internal server error.
I honestly don't know if this is to do with memory limits or what. Has anyone else come across this error?
A 500 is a generic error, can you check the server logs for specifics?
Or add this to the admin index.php right below the opening <?php
Code: Select all
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
...always us e a decent code editor like sublimetext
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
error with geozone at line 28 and line 30.
Attachments
Untitled.png (7.11 KiB) Viewed 1829 times
Untitled1.png (161.52 KiB) Viewed 1829 times
Code: Select all
foreach ($data['zone_to_geo_zone'] as $value) {//line 27
if(!isset($value['zone_id']))continue;//add this
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
error when login admin -> geozoneartcore wrote:Try this:
Code: Select all
foreach ($data['zone_to_geo_zone'] as $value) {//line 27 if(!isset($value['zone_id']))continue;//add this
Did you add the new line of code as I suggested at the exact spot?
What's the error?
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
I using new vers OPC. I set multi flat rate base on weight.artcore wrote:You have be more specific or no one will be able to assist.
Did you add the new line of code as I suggested at the exact spot?
What's the error?
My country have 63 provine, I set one provine have fee shipping 25.000 vnd, and other province (62 province) have fee shipping 30 000 vnd.
result:
+ One provine ( 25000 vnd) is ok, well done
+ and how other province (62 province) set? GEO zone must 63 option => save option, then edit is error with 500 internal, and losing zone. img attack error
Attachments
Untitled1.png (161.52 KiB) Viewed 1797 times
If so post the relevant error
Otherwise add this to admin/index.php right below the opening <?php
Code: Select all
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
in the admin root -> error_log:artcore wrote:A 500 server error is very generic. Do you have a file in the admin root -> error_log?
If so post the relevant error
Otherwise add this to admin/index.php right below the opening <?php
Visit the page again that causes the error and report the error message.Code: Select all
ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL);
"[05-Dec-2016 15:56:29 Asia/Ho_Chi_Minh] PHP Parse error: syntax error, unexpected 'public' (T_PUBLIC) in /home/xxx/public_html/admin/model/localisation/geo_zone.php on line 21
[05-Dec-2016 15:58:21 Asia/Ho_Chi_Minh] PHP Parse error: syntax error, unexpected 'public' (T_PUBLIC) in /home/xxx/public_html/admin/model/localisation/geo_zone.php on line 21"
Otherwise add this to admin/index.php right below the opening <?phpartcore wrote:A 500 server error is very generic. Do you have a file in the admin root -> error_log?
If so post the relevant error
Otherwise add this to admin/index.php right below the opening <?php
Visit the page again that causes the error and report the error message.Code: Select all
ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(E_ALL);
Code: Select all
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
phukienvatrangsuc.net is currently unable to handle this request.
HTTP ERROR 500"
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);"
I add above code at php.ini, and it create error_log.php, and notice:
"[06-Dec-2016 13:16:38 Asia/Ho_Chi_Minh] PHP Fatal error: Call to undefined function phpini_set() in /home/xxxxxx/public_html/index.php on line 1
[06-Dec-2016 13:16:59 Asia/Ho_Chi_Minh] PHP Fatal error: Call to undefined function phpini_set() in /home/xxxxxx/public_html/index.php on line 1"
I use original new vers, no new module, no SEO extension. language Vietnamese.
To know what causes the 500 error you need to have a detailed description which is either in the file 'error_log' in your admin folder. Or you change admin/index.php so it displays the error.
you put that code in a completely different file and expect it to work.
If it's related to php_max_inputs_vars, try saving geo zone with 20 zones, than 30 and so on until you get the error. Then ask your host to raise this value.
Attn: I no longer provide OpenCart extensions, nor future support - this includes forum posts.
Reason: OpenCart version 3+
Thanks!
[Tue Dec 06 14:45:09 2016] [error] [client 14.186.33.71] (12)Cannot allocate memory: couldn't create child process: /opt/suphp/sbin/suphp for /home"
I contact support with host server. But don't know it depend on what properties. memory? or max_input_vars???
I test, 5 input => no error. larger 5 input => error with 500 internal server
Thank you very much. Love

Users browsing this forum: Amazon [Bot] and 8 guests