iliaal / php_excel

PHP Extension interface to the Excel writing/reading library
http://ilia.ws
534 stars 131 forks source link

License Key does not work... Still in Trial Mode? #239

Closed EnVy28 closed 3 years ago

EnVy28 commented 6 years ago

Hi,

I recently purchased a libxl license for linux and I tried to make a PHP Extension without any problem. But when I tried to make a simple "hello world" test, a message saying its a trial mode still shows up.

As of right now, I have the latest version of libxl which is 3.8.3.0. My php version is 7.2.9.

When I purchased my LibXL license, I entered my company name as Japanese kanji so it came out as multi-byte Japanese characters. I wonder if that is problem?

I also noticed there is a way on how to get around this in the "Know issues" section but it doesn't seem to work, I still get the "This is a trial version" message on my excel files.

Also when compiling the extension, I followed the instructions written in the link below. https://blog.tiger-workshop.com/libxl-for-php-on-ubuntu-14-04-server/

The only thing I did differently is that, instead of adding my license name and key in excel.ini like below

; configuration for php excel module
; priority=30
extension=excel.so

[excel]
excel.license_name="漢字 Company Name 漢字"
excel.license_key="linux-xxxxxxxxxxxxxxxxxxxxx"
excel.skip_empty=0

I removed the excel section.

; configuration for php excel module
; priority=30
extension=excel.so

And instead put it in the instantiation instead.

$license_name = utf8_decode('漢字 Company Name 漢字');
$license_key = utf8_decode('linux-xxxxxxxxxxxxxxxxxxxxx');
$xlBook = new ExcelBook($license_name, $license_key, true); 

Mind that I also tried the solution written in the "Known issues" section but it does not worked.

class MyExcelBook extends \ExcelBook
{
    public function __construct($license_name=null, $license_key=null, $new_excel=false)
    {
        if (null === $license_name) {
            $license_name = utf8_decode(utf8_decode('漢字 Company Name 漢字'));
            $license_key = utf8_decode(utf8_decode('linux-xxxxxxxxxxxxxxxxxxxxx'));
        }
        parent::__construct($license_name, $license_key, $new_excel);
        $this->setLocale('UTF-8');
    }
}

$xlBook = new MyExcelBook(null, null, true); 

One more thing, I tested it in 2 different servers, both are running CentOS7, but 1 is running inside virtualBox in Vagrant. And the other 1 is running in Hyper-V (without vagrant, just plain hyper-v). Both with the same result.

Am I doing something wrong?

johmue commented 6 years ago

You should ask for non-unicode license keys - it will remain constant pain if you stick to the unicode ones.

EnVy28 commented 6 years ago

@johmue Yeah I figured it would be easier to use a non-unicode license key instead too. I already sent a ticket to LibXL about it. Thank you.

over-write commented 6 years ago

Me too. I used japanese name. Not Authorized,Trial mode. @EnVy28 Did you have contact from support? My Ticket was not replay yet.

over-write commented 5 years ago

Support changed license_name to only alpabet name. Change the licence , when this probrem was resolved.