Koozali.org: home of the SME Server

Trouble with php scripts

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Trouble with php scripts
« on: December 13, 2004, 02:48:55 PM »
I am trying to install a site builder program, (Freehostshop) and am having trouble getting one function to work. According to the vendor, he said
Quote
An other reason can be that the php.ini file on your webserver is set to not allow url includes


Is this possible, and how can I correct it?

I know nothing about php.


Thanks
If you think you know whats going on, you obviously have no idea whats going on!

Offline TrevorB

  • *
  • 259
  • +0/-0
    • http://www.batley.id.au
Trouble with php scripts
« Reply #1 on: December 14, 2004, 01:07:54 AM »
Is there anything in the logs to show what is wrong?

Look in /var/log/messages.

Trevor B

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Trouble with php scripts
« Reply #2 on: December 14, 2004, 05:33:32 AM »
I dont see anything in the log file revering to the program I am tring to run

Bob
If you think you know whats going on, you obviously have no idea whats going on!

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Trouble with php scripts
« Reply #3 on: May 05, 2005, 06:57:19 AM »
I have tried this again, and this time Ihave error messages as follows
Quote
May  5 00:33:21 server1 httpd: PHP Warning:  Unknown(): URL file-access is disabled in the server configuration in /home/e-smith/files/ibays/test/html/siteadmin/top.php(3) : eval()'d code(1) : eval()'d code on line 11
May  5 00:33:21 server1 httpd: PHP Warning:  Unknown(http://freehostshop.com/wglib/settings/toplocked33.inc): failed to open stream: no suitable wrapper could be found in /home/e-smith/files/ibays/test/html/siteadmin/top.php(3) : eval()'d code(1) : eval()'d code on line 11
May  5 00:33:21 server1 httpd: PHP Warning:  (null)(): Failed opening 'http://freehostshop.com/wglib/settings/toplocked33.inc' for inclusion (include_path='.:/usr/share/pear') in /home/e-smith/files/ibays/test/html/siteadmin/top.php(3) : eval()'d code(1) : eval()'d code on line 11
May  5 00:33:25 server1 httpd: PHP Warning:  main(): URL file-access is disabled in the server configuration in /home/e-smith/files/ibays/test/html/siteadmin/templateselect.php on line 3
May  5 00:33:25 server1 httpd: PHP Warning:  main(http://srdpc.com/wglib/templates/templateselect.inc): failed to open stream: no suitable wrapper could be found in /home/e-smith/files/ibays/test/html/siteadmin/templateselect.php on line 3
May  5 00:33:25 server1 httpd: PHP Warning:  main(): Failed opening 'http://srdpc.com/wglib/templates/templateselect.inc' for inclusion (include_path='.:/usr/share/pear') in /home/e-smith/files/ibays/test/html/siteadmin/templateselect.php on line 3


I have remarked out the lines in httpd.conf tha alias the files directory for the ibay I am using. Is there someplace else I have to make a change to allow access to the files folder? I am not actually using the files folder that sme creates, but a folder called files that is in the html folder.

I am using the server as a web/mail server, so not blocking the files directory is not an issue in this case.

Thanks

Bob
If you think you know whats going on, you obviously have no idea whats going on!

Offline edb

  • *
  • 548
  • +0/-0
Trouble with php scripts
« Reply #4 on: May 06, 2005, 06:44:51 AM »
Looks like you need to specify the path to your includes directory.
You will probably need to create a custom-template fragment "50PathsDirectories" and add/modify the line:

include_path = ".:/home/esmith/files/ibays/test/include:/usr/share/pear"

then expand the template and restart httpd.

The order is important.
......

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Trouble with php scripts
« Reply #5 on: May 07, 2005, 05:37:37 AM »
Thanks for pointing me in some direction edb. Tried what you suggested, but it did not work. did a little digging, and made the mods to the templet fragment for php.ini, and it added the line, but did not fix the problem.

 Two or three things are hindering me trying to get this to work.
1- I am still a newbie.
2- the php script I am using has much of the code encripted, an I am not getting much help from the vendor, and
3- I do not have a lot of time during the week to play with it, But I am trying.

I do appreciate you input, and am looking for all possible suggestions.

Thanks

Bob
If you think you know whats going on, you obviously have no idea whats going on!

Offline edb

  • *
  • 548
  • +0/-0
Trouble with php scripts
« Reply #6 on: May 07, 2005, 08:42:28 AM »
If your PHP pages are encrypted then you will also need the mcrypt & mhash rpms installed. They are part of the script but are commented by default.
Ask your vendor if they are using mcrypt encryption.
If the answer is yes, then go and look at the php script for the download locations and download the missing two rpms.
......

Offline crazybob

  • *****
  • 894
  • +0/-0
    • Stalzer R&D
Trouble with php scripts
« Reply #7 on: May 07, 2005, 02:43:39 PM »
I will ask about, thanks. I also just received reply from him and he said to add
Quote
change the setting in php.ini to allow_url_fopen as follows: allow_url_fopen = On


Are there any issues I should be worried about doing this. Checking my current php settings I see this is set to off by default.
If this will not cause any problems, I will be trying it the first part of next week


Thanks

Bob
If you think you know whats going on, you obviously have no idea whats going on!