PDA

View Full Version : Access Issue to Data folder on Windows Server

tjanders
December 10th, 2005, 04:50 PM
I'm having problems with create / write permissions to the photopost/data folder. I keep getting a message to this effect at the last stage of installation. I'm on a Windows server. I've tried setting folder permissions for scripts, browsing and program execution but without any success. My understanding is that the folder is definitely writeable.

There is no issue with the MYSQL database as the tables create successfully. Do you have any recommendations on how get past this permissions on the photopost/data folder on a Windows server?

It's also a little troublesome that the warning message is consistently missing a back slash prior to my domain name and the first letter of my domain name.
***
On further work on this problem, the program defaulted back slashes for the location of the photopost/data folder. When all back slashes are changed to front slashes, the install proceeds and completes. However the admin control panel cannot be accessed. All the error messages indicate the program is still using backslashes elsewhere, specifically in trying to locate header-inc.php and global.php on login. The program code defaults to backslash instead of frontslash and so nothing runs.

Chuck S
December 10th, 2005, 06:24 PM
Hello when installing on a windows domain the number one issue I see is people forget in the windows environment on php it is suggested you need to use forward slashes not backslashes. backslashes will be stripped in PHP.

This would be your issue with urls and path statements I would assume here.

You would need to post error messages you recieve for me to say anything more here.

tjanders
December 11th, 2005, 01:11 AM
Are you saying I need to go through all the php files, find file references and change all the back slashes to forward? Yikes. Didn't have any trouble at all with back slashes when installing vBulletin on this Windows server, so I'm surprised to have this coding problem.

Here's the feedback currently surrounding the admin panel logon:

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\Domains\timstropicals.com\wwwroot\photopost\forums\photopost.php on line 25

Here's the feedback if I simply enter my URL with /photopost appended:

Warning: chdir(): No such file or directory (errno 2) in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 60

Warning: main(./global.php): failed to open stream: No such file or directory in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 61

Fatal error: main(): Failed opening required './global.php' (include_path='.;c:\php\includes') in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 61
PHP Warning: chdir(): No such file or directory (errno 2) in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 60 PHP Warning: main(./global.php): failed to open stream: No such file or directory in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 61 PHP Fatal error: main(): Failed opening required './global.php' (include_path='.;c:\php\includes') in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 61

All the slashes are the opposite direction of what I had to enter during the install, but all are consistent with normal programming on a Windows server (except the './global.php')

Subsequently, I also tried a complete reinstall and this time used "\\" for every back slash on installation screens. This time it gave me the option to access the admin control panel and sent me to a working logon in adm-index.php (no idea what username or password to try) but then it gives the same coding errors as above for accessing the forum if I complete the form with anything. The "Register" button does invoke my vbulletin registrations screen, though. Seems to me this is the user logon, not an admin panel logon despite what the url says.

Well, I've invested 6.5 hours on this today, so hopefully tomorrow will be more productive.

Chuck S
December 11th, 2005, 07:43 AM
Are you saying I need to go through all the php files, find file references and change all the back slashes to forward? Yikes. Didn't have any trouble at all with back slashes when installing vBulletin on this Windows server, so I'm surprised to have this coding problem.

Nope has nothing to do with coding ;) I am refering to server path translation. There are literally thousands of threads on the internet about windows and server path translation. You need to use forward slashes when your storing a variable in a mysql database. Backslashes will be stripped in mysql.

D:\some\path\to\photopost WRONG

D:/some/path/to/photopost RIGHT

Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in C:\Domains\timstropicals.com\wwwroot\photopost\forums\photopost.php on line 25

Are you intergrated with vbulletin or installing as an internal install that error suggests you have selected internal install so its loading photopost intergration. You would need to rerun install.php and select vbulletin integration or you can edit the settings mysql table line 41 and change the entry to vb3

Warning: chdir(): No such file or directory (errno 2) in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 60

Warning: main(./global.php): failed to open stream: No such file or directory in C:\Domains\timstropicals.com\wwwroot\photopost\header-inc.php on line 61

Okay in your integration settings in admin panel or config-int.php file your $vbpath is not set correctly. chdir($vbpath);
require("./global.php");

Thus you need to set the variable \$vbpath to the correct server path of vbulletin.

This is what those errors suggest to me here.

tjanders
December 11th, 2005, 09:20 PM
Wow, an awful lot of time spent on some simple issues. The problem was first the front slash issue and second the integration. On implementation screen 4, I chose a vBulletin path. Then on screen 5 the first Forum path defaulted to a photopost/forum path. I accepted this, thinking the gallery forum runs in photopost not vbulletin. Two lines down, I left the coding as vBulletin for the forum url thinking this was the registration integration. Obviously a conflict. Obviously integration means more than forum logon.

Next hurdle was that I couldn't get in to the admin problem. Again an integration problem. I used the forum to discover that my cookies abolutely had to be set to "bb" despite me somehow thinking I was some kind of special exemption. Also had to readjust the Forum domain cookies to .mysite.com in PHP Admin

Finally a control panel and a running gallery! Thanks for your patience.

Chuck S
December 12th, 2005, 05:58 AM
Not a problem at all.