Saturday, 17 December 2016

Fatal error: Call to undefined function curl_init() in admin/controller/sale/order.php on line 84 - opencart

 When using the curl functionalities you need to enable the extension in your php.ini file

on windows:
extension=php_curl.dll

on linux*:
extension=php_curl.so




It could happen, for example, on opencart with this error:
Fatal error: Call to undefined function curl_init() in admin/controller/sale/order.php on line 84 -

Tuesday, 13 December 2016

[FIX] PHPmyadmin - Fatal error: main(): The script tried to execute a method or access

Fatal error: main(): The script tried to execute a method or access a property of an incomplete object. Please ensure that the class definition "PMA\libraries\ThemeManager" of the object you are trying to operate on was loaded _before_ unserialize() gets called or provide a __autoload() function to load the class definition in \libraries\common.inc.php on line 702


Fast solution - Just delete the cache in your browser :)

Thursday, 8 December 2016

Force ssl for all the pages (single domain) - force ssl for opencart



 #add this after RewriteEngine On and add your domain where to redirect

RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://www.yourdomain.com/$1 [L,R=301]

Tuesday, 6 December 2016

iframe not positioned correctly in chrome or safari (webkit) with rtl (ex. arabic language)


 iframe not positioned correctly in chrome or safari (webkit) with rtl (ex. arabic language)


I got a problem with an iframe like this one
<iframe src="page.html" width="360px" height="120px" marginwidth="0" marginheight="0" hspace="0" vspace="0" frameborder="0" scrolling="no"></iframe>


I solved by just setting a fixed width from the CSS and chrome positioned the iframe as expected.

I spent 1 hour on this stupid thing and I really don't like to fix such an old crap.