Solved

Installing ionCube on GoDaddy server using PHP

Posted on 2008-10-01
4
3,289 Views
Last Modified: 2013-12-13
I am trying to use Easy PHP Calendar and it is requiring ionCube loader on the server.  The problem is that I just can/t get it running.  I am using the GoDaddy servers and, because they don't supply this product themselves, they will not help with this.

I am starting with just getting the basic ioncube-loader-helper.php to be happy.  When it runs it just tells me:

    An ionCube Loader file is required by PHP to
    read files encoded with the ionCube Encoder.
    This page will determine how you can install
    Loaders on this particular server.

    The loading of ionCube encoded files is not
    currently working correctly on this server.

I figure that once this shows no problems then I can tackle getting the calendar application to run.


Here is what I have done so far:

* Since GoDaddy tells me that either 32 or 64 bit applications will run, I have selected the 32-64 bit version of the files.

* The version of PHP running is 5.2, so I selected the 5.2 versions of the files.

* I uploaded both the non-threadsafe file ioncube_loader_lin_5.2.so and the threadsafe file ioncube_loader_lin_5.2_ts.so to an "ioncube" folder off of the root folder on the site.

* I then first tried the suggested instructions by putting in this change to the php.ini file in the root of the site (I have obscured the path, but I confirmed that it was correct by looking at $_SERVER['DOCUMENT_ROOT'].)

[Zend]
zend_extension=/home/content/a/b/c/my.www.serverdir/html/ioncube/ioncube_loader_lin_5.2.so
zend_extension=/usr/local/zo/ZendExtensionManager.so
zend_extension=/usr/local/zo/4_3/ZendOptimizer.so

Both with and without the 'Zend' section.

* I then tried it using both the non-thread and threadsafe entries (both with and without the 'Zend' section):

zend_extension=/home/content/a/b/c/my.www.serverdir/html/ioncube/ioncube_loader_lin_5.2.so
zend_extension_ts=/home/content/a/b/c/my.www.serverdir/html/ioncube/ioncube_loader_lin_5.2_ts.so

* I then found an interesting page in the GoDaddy help and I tried this in the php.ini file (both with and without the 'Zend' section):

[Zend]
zend_extension=/home/content/a/b/c/my.www.serverdir/html/ioncube/ioncube_loader_lin_5.2.so
zend_extension_ts=/home/content/a/b/c/my.www.serverdir/html/ioncube/ioncube_loader_lin_5.2_ts.so
zend_optimizer.optimization_level=15
zend_extension_manager.optimizer=/usr/local/Zend/lib/Optimizer-2.5.7
zend_extension_manager.optimizer_ts=/usr/local/Zend/lib/Optimizer_TS-2.5.7
zend_extension=/usr/local/Zend/lib/ZendExtensionManager.so
zend_extension_ts=/usr/local/Zend/lib/ZendExtensionManager_TS.so


I was told that changes to the php.ini files take affect when they are uploaded.  Maybe this is incorrect.  How can I send a command, in PHP, to re-read the php.ini file.  

I would need to use PHP script, because I can't restart PHP on the GoDaddy server.

What step am I missing?  What configuration am I missing?  

Is there no hope in it working on this server?
0
Comment
Question by:stpatrickjr
  • 2
4 Comments
 
LVL 6

Expert Comment

by:deresh
ID: 22653321
the only way is to restart apache if php is loaded as module. if it runs as CGI it should pick-up changes when it's started next time ( first next access to server). i don't know for fastcgi
0
 

Accepted Solution

by:
stpatrickjr earned 0 total points
ID: 22655686
OK, for everyone out there, here is how to get it to work:

Information for this Configuration
-----------------------------------
Server - GoDaddy
PHP Version - 5.2

How to Set Up
----------------
Use the ionCube files from the 32-bit set, not the 32-64 bit, as implied by GoDaddy stating that it supports 32-64 bits:
ioncube_loader_lin_5.2.so
ioncube_loader_lin_5.2_ts.so

Copy them into an "ioncube" folder in your website root.

Get the physical path to the "ioncube" folder. This is the /home/content/..../html/ioncube/ location to your website. You can find this by looking at the $_SERVER['PHPRC'] variable with a server script.

Edit the php.ini in your root folder. You may already have some settings in a Zend section, but they are wrong. Add this section, being sure that the ioncube entries are FIRST.

(Note: Replace the path to the site's folder with your path, as determined above.)

[Zend]
zend_extension=/home/content/a/b/c/mysite/html/ioncube/ioncube_loader_lin_5.2.so
zend_extension_ts=/home/content/a/b/c/mysite/html/ioncube/ioncube_loader_lin_5.2_ts.so
zend_optimizer.optimization_level=15
zend_extension_manager.optimizer=/usr/local/Zend/lib/Optimizer-2.5.7
zend_extension_manager.optimizer_ts=/usr/local/Zend/lib/Optimizer_TS-2.5.7
zend_extension=/usr/local/Zend/lib/ZendExtensionManager.so
zend_extension_ts=/usr/local/Zend/lib/ZendExtensionManager_TS.so

Copy the ioncube-loader-helper.php file to the root of your website (I am not sure if it is needed, but it worked for me.)

Run the ioncube-loader-helper.php file.

This, finally, performs its magic and starts it working.
0
 

Author Comment

by:stpatrickjr
ID: 22655699
You may want to keep this for any other poor soul who tries to get this to work.
0
 

Expert Comment

by:alanhelmick
ID: 24402837
Solution Works for Godaddy Linux Ion Cube Error

You do not need to to copy the php file anywhere...the php.ini file settings changes are the trick.

1.  Make them first in the file.
2.  I was extra sure and made a php5.ini, exactly the same and uploaded it... although I think this was unnecessary.

An actual solution that works.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Generating table dynamically is the most common issue faced by php developers.... So it seems there is a need of an article that explains the basic concept of generating tables dynamically. It just requires a basic knowledge of html and little maths…
Things That Drive Us Nuts Have you noticed the use of the reCaptcha feature at EE and other web sites?  It wants you to read and retype something that looks like this.Insanity!  It's not EE's fault - that's just the way reCaptcha works.  But it is …
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now