[solved] import function, undefined function zlib_encode

More
10 years 4 months ago #47911 by ggppdk
hello,
busy and been sick these days

test this fix, that detects PHP version (so that you do not to wait for this to be tested/commited):

1. in files:
administrator\components\com_flexicontent\controllers\import.php(117)
administrator\components\com_flexicontent\controllers\import.raw.php(48)
administrator\components\com_flexicontent\views\import\view.html.php(71)

replace:
Code:
$conf = unserialize( $conf ? zlib_decode(base64_decode($conf)) : "" );
with
Code:
$has_zlib = version_compare(PHP_VERSION, '5.4.0', '>='); $conf = unserialize( $conf ? ($has_zlib ? zlib_decode(base64_decode($conf)) : base64_decode($conf)) : "" );




2. in file:
administrator\components\com_flexicontent\controllers\import.php

replace:
Code:
$conf = base64_encode(zlib_encode(serialize(null), -15));
with:
Code:
$has_zlib = version_compare(PHP_VERSION, '5.4.0', '>='); $conf = $has_zlib ? base64_encode(zlib_encode(serialize(null), -15)) : base64_encode(serialize(null));

and replace:
Code:
$session->set('csvimport_config', base64_encode(zlib_encode(serialize($conf), -15)), 'flexicontent');
with:
Code:
$has_zlib = version_compare(PHP_VERSION, '5.4.0', '>='); $session->set('csvimport_config', ( $has_zlib ? base64_encode(zlib_encode(serialize($conf), -15)) : base64_encode(serialize($conf)) ), 'flexicontent');


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
10 years 4 months ago #47922 by tonnick
ok it seems to be ok ! thx for you help and get well !

Please Log in or Create an account to join the conversation.

More
10 years 4 months ago #47925 by ggppdk
Hello

ok, thanks for feedback

commited this fix


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.394 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline