ionCube Logo
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


 
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder

__DIR__ and PHP 5.6 not correct

Author Message
yabz



Joined: 31 Jan 2019
Posts: 1

PostPosted: Thu Jan 31, 2019 10:39 am    Post subject: __DIR__ and PHP 5.6 not correct Reply with quote

I am having an issue with an encoded file.

I encoded with Encoder 10 and set it to 10.2

The server is running PHP 5.6

Here is the code...

Code:
require __DIR__ . '/vendor/autoload.php';


when the encoded file is requested it is ignoring the __DIR__ altogether and giving the following error...

Code:
PHP Fatal error:  main(): Failed opening required '/home/test/public_html/somesite.com/vendor/autoload.php' (include_path='.:/opt/alt/php56/usr/share/pear:/opt/alt/php56/usr/share/php') in /home/gnosisme/public_html/masashland.com/cmsgo.class.php on line 0


It looks like ioncube is is preventing the magic constant __DIR__ from parsing the correct path. It is using a blank value instead.

This same code works fine when not encoded.

Is there a special trick I need to do to make this work as an encoded file?

Maybe I am encoding the file wrong?

Thanks for any help.
Back to top
View user's profile Send private message
alastair



Joined: 23 Feb 2010
Posts: 354

PostPosted: Tue Feb 19, 2019 5:10 pm    Post subject: Reply with quote

Hi,

If you have not done so already it would be best to create a ticket in our Support Help Desk at https://support.ioncube.com
_________________
Alastair

ionCube
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum