Jump to content

Register Globals error


redham

Recommended Posts

I'm attempting to install WHMCS but I got a "Register Globals must be on" error. I turned on Register Globals using a php.ini file with the command:

register_globals = On

 

I placed a info.php file into the whmcs directory and indeed it shows reg_global as turned on yet I still get the same error when I attempt to run the setup script. It's not recognizing that the Register Globals have been turned on.

 

Any ideas?

 

redham

Link to comment
Share on other sites

Try using a .htaccess file to activate it on WHMCS's folder..

There is a lot of talk around Register Globals' safety so you may want to leave it off globally and activate on each directory needed..

 

just put the following into your whmcs's directory's .htaccess

php_flag register_globals on

 

C'ya

Link to comment
Share on other sites

I'm attempting to install WHMCS but I got a "Register Globals must be on" error. I turned on Register Globals using a php.ini file with the command:

register_globals = On

 

I placed a info.php file into the whmcs directory and indeed it shows reg_global as turned on yet I still get the same error when I attempt to run the setup script. It's not recognizing that the Register Globals have been turned on.

 

Any ideas?

 

redham

 

Hey,

 

In order for the php.ini file to be active, you will need to put it in each folder, so the root whmcs folder and any other folder.

 

From what I recall, you can only need to put the php.ini file in the root whmcs folder and admin folder.

 

From,

Adam

Link to comment
Share on other sites

Hi,

Thanks for answering.

The .htaccess code was a little different than :

php_flag register_globals on

I used :

php_value register_globals on

BUT I got a server error so now I used php.ini

register_globals = On

But it won't work.

And I tried putting it in the admin folder as well but still no dice. I think that a php.ini affects all folders under it. For example if you put one in the site root it would affect the entire account until another php.ini change it.

 

This has got to be something simple but I just can't seem to find it.

 

redham

Link to comment
Share on other sites

I did not know you had to put php.ini on every folder to activate it...

 

Hey,

 

Yes, this only happens with php.ini files, .htaccess files you can put in the root whmcs folder and every folder below it will work fine.

 

Depending on your the what modules you have installed on your server, you can not use PHP options in a .htaccess file...

 

From,

Adam

Link to comment
Share on other sites

Hi,

Thanks for answering.

The .htaccess code was a little different than :

php_flag register_globals on

I used :

php_value register_globals on

BUT I got a server error so now I used php.ini

register_globals = On

But it won't work.

And I tried putting it in the admin folder as well but still no dice. I think that a php.ini affects all folders under it. For example if you put one in the site root it would affect the entire account until another php.ini change it.

 

This has got to be something simple but I just can't seem to find it.

 

redham

 

Hey,

 

"If you don't want to turn Register Globals on for your whole server or don't have access to as you are a reseller then you can enable them just on the whmcs folder and all subfolders below it. To do this, simply put the following line into a text file and save it as ".htaccess". Then upload it to your WHMCS folder.

 

php_value register_globals on

 

Sometimes, the .htaccess method will not work on your server and you'll get an Internal Server Error message after trying that. In the event of this, you can try using a php.ini file. To do this, create a file named "php.ini" and insert the following line:

 

register_globals=On

zend_extension = /path/to/ioncube/ioncube_loader_lin_4.4.so

 

Then upload the php.ini file to the main folder, admin folder & install folder (if exists) of WHMCS."

 

Taken from,

http://support.whmcs.com/knowledgebase.php?action=displayarticle&catid=4&id=5

 

You don't have php.ini in your install folder,

http://www.glitterhost.com/whmcs/install/php.ini

 

and

 

http://www.glitterhost.com/whmcs/php.ini

 

should be

 

register_globals=On

 

From,

Adam

Link to comment
Share on other sites

Yes I read that knowledge base answer.

The .htaccess gives the server error.

Question about the php.ini

on the line "zend_extension = /path/to/ioncube/ioncube_loader_lin_4.4.so" do I leave that path as is or should I put:

"/ioncube/" since ioncube is in the whmcs directory?

 

redham

Link to comment
Share on other sites

Yes I read that knowledge base answer.

The .htaccess gives the server error.

Question about the php.ini

on the line "zend_extension = /path/to/ioncube/ioncube_loader_lin_4.4.so" do I leave that path as is or should I put:

"/ioncube/" since ioncube is in the whmcs directory?

 

redham

 

You can leave it blank, but if you want to put it in, it will be the full path to ioncube.

 

So,

 

/home/cpaneluser/public_html/ioncube/ioncube_loader_lin_4.4.so

 

From,

Adam

Link to comment
Share on other sites

I got it finally. I should slow down and read everything!

 

After I put the php.ini in the other two folders

main folder, admin folder & install folder
as Adam posted it worked smooth as glass.

 

 

Thanks for the help guys.

 

redham

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated