| Author | Post |
|---|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Wed Jun 4th, 2008 07:56 pm |
|
I put an .htaccess file in the 'default' directory so it would be copied/included in any new users folders via the 'add_new_member' process....no joy.
Any solution?
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Thu Jun 5th, 2008 03:55 pm |
|
An .htaccess is a communication between the server and a browser only. It does not actually make the files available through the file system.
Add the files in the 'default' directory to the populate_from directory. The add_new_member automatically copies all files in the populate_from directory to the new_user's directory when creating the new user.
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Thu Jun 5th, 2008 04:45 pm |
|
| So, you're saying Editwrx won't copy an .htaccess file from the populate_from directory to the new_user's directory?
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Thu Jun 5th, 2008 04:58 pm |
|
| EditWrx is entirely unaware of the content of .htaccess files. Like I said, htaccess is not part of the filesystem, it is part of the environment envelope
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Thu Jun 5th, 2008 07:39 pm |
|
OK. I understood your point from the the get-go. .htaccess is a file, nevertheless. So, I'll have to handle my inclusion of this file in a a higher level directory.
Thanks for the answer.
Did you get around to my css style cataloging queston, yet?
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Thu Jun 5th, 2008 08:29 pm |
|
If you want to add an .htaccess file to a new user's directory, place the .htaccess in the populate_from folder.
The css was answered on that thread.http://www.editwrx.com/forums/view_topic.php?id=129&forum_id=12&jump_to=1316#p1316
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Thu Jun 5th, 2008 11:01 pm |
|
| As I stated in the beginning of this thread, the .htaccess file is in the populate_from folder. It simply is not getting copied to the new_user's folder by the add_new_member page script.
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Fri Jun 6th, 2008 04:44 pm |
|
I was unaware that Perl's glob function, by default, does not catalog hidden system files like .htaccess.
Open /editwrx/ini/catalog.txt and change the code to
$U = "a";
$V = 1;
$W = $U.$V;
$folder_to_populate_from=~s` `\ `g;
@things=<$folder_to_populate_from/.* $folder_to_populate_from/*>;
foreach $thing (@things){
if(-f $thing){push(@FILES,$thing)}
if(-d $thing){
push(@DIRS,$thing);
$THNG=$thing;
$THNG=~s` `\ `g;
@dir=<$THNG/*>;
push(@$W,@dir);
}
}
&cycle;
sub cycle{
foreach $thing (@$W){
if(-f $thing){push(@FILES,$thing)}
if(-d $thing){
push(@DIRS,$thing);
$THNG=$thing;
$THNG=~s` `\ `g;
@dir=<$THNG/.* $THNG/*>;
push(@X,@dir);
}
}
if($#X > -1){++$V;$W = $U.$V;@$W=@X;@X=();&cycle}
}#cycle
1;
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Fri Jun 6th, 2008 05:12 pm |
|
Software error:
syntax error at /usr/www/users/lpfqs1wg/AreaEditor/editwrx/library/ini/catalog.txt line 1, near ""$U = "a"
Compilation failed in require at /usr/www/users/lpfqs1wg/AreaEditor/editwrx/library/routines.txt line 103.
BTW: You meant for me to change catalog.txt in ...editwrx/library/ini/ not ...editwrx/ini/ right?
Last edited on Fri Jun 6th, 2008 05:16 pm by rcadby |
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Fri Jun 6th, 2008 05:28 pm |
|
Oops. My bad. I included the double quotes in the change to the catalog.txt file, but it's hanging up the browser now trying to add the new user.
So ignore the previous error report.
But, the browser timed out, the new user files were indeed genterated except the .htaccess file wasn't copied, so no joy, yet.
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Fri Jun 6th, 2008 06:01 pm |
|
Opps.
The line near the bottom with
@dir=<$THNG/.* $THNG/*>;
should be
@dir=<$THNG/*>;
BTW I logged into your installation at areaeditor and changed that for you.
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Fri Jun 6th, 2008 07:22 pm |
|
OK! We indeed got the .htaccess file copied.
But, I still got 'timed out' after new user addition, got a bad 'new user' login and the new user did not show among the admin users.
Try the add_new_member.php in Future Gold and see if it happens to you.Last edited on Fri Jun 6th, 2008 07:23 pm by rcadby |
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Sat Jun 7th, 2008 04:38 pm |
|
| Is the new user getting added to the data/users.txt for that domain?
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Sat Jun 7th, 2008 06:58 pm |
|
Yes.
Browser still times out, though..doesn't finish the addition process. nu_user files are in place (e.g. http://futuregold.org/StPaulMN/), can open new pages there, but can't log in, "StPaulMN" user is not showing when logging in as "admin".
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Mon Jun 9th, 2008 05:26 pm |
|
The user, and "admin", for futuregold must login at futuregold.org/editwrx/wrx.wcgi, not at the parent areaeditor.
If you login there as admin you'll see all of the users for futuregold listed in the Change User list.
A child installation is a child only in that it uses the routines.txt, library/ini & /library/htm of the parent. Otherwise a child is exactly like any other installation. A child has it's own cgi script and it's own /library/data files.
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Mon Jun 9th, 2008 08:07 pm |
|
Well, that's not 'it'.
I went back to 'square one', put back the original catalog.txt file, added new user "testing", pwd "tester", and it dutifully copied all files (except for .htaccess), went instantly to the instruction page without timing out, allowed logging in, admin shows the new user "testing"...
In other words the revised catalog.txt page is causing problems when creating a new user. Another problem it causes is the time-delay/inability to delete a user via admin. (Yes, I've been using the correct admin from Future Gold right along).
If you can put the revised catalog.txt file back in (or I will if you like) and please try futuregold.org/add_new_user.php you should see what happens.
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Mon Jun 9th, 2008 08:42 pm |
|
You have not been logging in from futurgold - I had to create the wrx.wcgi file at futuregold myself this morning :-)
Your server is not running a standard suExec. It is a Pair server running their proprietary cgi-wrap instead. Their cgi-wrap prohibits listing a hidden system file like .htaccess in a directory listing.
So, I added a routine in add_nu_user.txt that copies any .htaccess file from the $folder_to_populate_from into the $users_folder.
I gave add_nu_user.txt 0444 permissions so it wont get overwritten by an update or by FTP unless it's permission is changed back to 0644;
I added a new user, edited it in Change User and then deleted it w/no problems.
|
rcadby Member
| Joined: | Tue Apr 4th, 2006 |
| Location: | |
| Posts: | 21 |
|
Posted: Mon Jun 9th, 2008 10:35 pm |
|
OK. I'm totally confused now.
I changed the catalog.txt to be the modified one you wanted and when I tried deleting user "tester" I got a message saying 'can't delete files'. Admin showed it gone, user.txt showed it gone, ftp showed files still there. Then I had to make several attempts via ftp (got errors) to delete those files.
With new catalog.txt code it still does not complete the addition, times out, "tester" user not in user.txt nor in admin.
I'm about at the point where I'll settle for adding the danged .htaccess file to each new user folder manually and just use the 'old' original catalog.txt file.
You said you had it working this morning? That really baffles me. Putting the wrx.wcgi into the domain has not been necessary in other domains because the cgi-bin of all domains as well as "editwrx" are all symbolically linked to the server's public cgi-bin. That makes the cgi-wrap work for all domains.
Well, I reinstated catalog.txt back to the original and successfully added "testing2", pwd "tester2", including (believe it or not, the .htaccess file), but could not do a normal user delete (refused to delete the files). <sigh>
I'm about to give up.
|
Keith Moderator
| Joined: | Fri Apr 8th, 2005 |
| Location: | |
| Posts: | 583 |
|
Posted: Tue Jun 10th, 2008 03:49 pm |
|
Why did you change catalog.txt? I said, I added the routine for copying the htaccess file to add_nu_user.txt since Pairs prohibits it being in catalog.txt. Of course it will now add the htaccess file - that because I added a routine to do that in add_nu_user.txt.
You MUST use the wrx.wcgi in futuregold! Period. A symlinked wrx.wcgi in the domain areaeditor has the wrong OWNERSHIP to work on files in other domains. OWNERSHIP is what cgi-wrap enforces and Pairs proprietary mickey mouse version will prohibit all kinds of things with wrong ownership, including the deleting of files that the cgi script does not own.
|
 Current time is 05:35 pm | |
|