Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 [2] 3

Author Topic: 'Excluding' Directory  (Read 10362 times)

brauck

  • Hero Member
  • *****
  • Karma: 18
  • Posts: 556
    • http://www.hbw-webdesign.nl/
'Excluding' Directory
« Reply #15 on: December 02, 2006, 02:42:13 pm »

Try this Tim:

.htaccess:
Code: [Select]
Redirect permanent / http://www.youdomain/snews/For more info see this
Logged
Confidence is reduced complexity.
brauck.nl for free css templates

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #16 on: December 02, 2006, 02:51:07 pm »

Hi Brauck,

When I tried your solution, I got this error in Firefox:

Code: [Select]
The page isn't redirecting properly
Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

    *   This problem can sometimes be caused by disabling or refusing to accept
          cookies.
And the URL 'looping' like this:

http://www.timrowe.co.uk/snews/snews/snews/snews/snews/snews/snews

I'll have a look at the Apache link you sent, but I suspect only a small percentage will make any sense to me :)

Best,
Tim
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • I'm a self-made man and worships my creator.
    • p-ahlqvist.com
'Excluding' Directory
« Reply #17 on: December 02, 2006, 02:53:48 pm »

Please also post you're current .htaccess here for us to view, Tim... And... Is there possibly a .htaccess for wordpress aswell ? Problems with that in such case ?
Logged
"It's only dead fish that goes with the flow... "
Updated

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #18 on: December 02, 2006, 03:52:21 pm »

..... rushes back from lunch .....

Good points Patric

My Wordpress set up doesn't currently have one, but sNews is:

Code: [Select]

    php_value session.use_trans_sid 0

RewriteEngine On
#RewriteBase /sNews15-DesignCriativo
RewriteCond %{REQUEST_FILENAME} -f
RewriteRule ^(.*) $1 [L]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^(.*)$ index.php?category=$1 [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?category=$1 [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([a-z_]+)/([^/]+) index.php?category=$1&title=$2 [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([a-z_]+)/([^/]+)/([^/]+)/ index.php?category=$1&title=$2&commentspage=$3 [L]
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([a-z0-9_-]+)/([0-9]+)/ index.php?category=$1 articlespage=$2 [L]
Redirect permanent / http://www.timrowe.co.uk/snews/
And, this may seem lik a dumb question, but in this case does .htaccess go inside 'root' or 'snews' directory?
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • I'm a self-made man and worships my creator.
    • p-ahlqvist.com
'Excluding' Directory
« Reply #19 on: December 02, 2006, 04:05:11 pm »

I would think into the location where the snews.php resides...
Logged
"It's only dead fish that goes with the flow... "
Updated

Keyrocks

  • Doug
  • ULTIMATE member
  • ******
  • Karma: 449
  • Posts: 6020
  • Semantically Challenged
    • snews.ca
'Excluding' Directory
« Reply #20 on: December 02, 2006, 04:06:23 pm »

.htaccess MUST be in the same directory as all your sNews files & folders... the sNews Root if you like. Which is why it's good to have them all in their own directory as brauk suggested (and I think you did) - this keeps all the snews stuff in one place and... at the same time... isolated from files and folders located outside that directory. sNews is configured to find all of its related files and folders within its own root "group.
Logged
Do it now... later may not come.
-------------------------------------------------------------------------------------------------
sNews 1.6 MESU | sNews 1.6 MEMU

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #21 on: December 02, 2006, 04:11:03 pm »

Thanks Keyrocks (and Patric).

I suspected it needed to be in the 'sNews' directory. Now I'll try and figure out *exactly* what addition is needed to .htaccess to make it work.

Best,
Tim
Logged

brauck

  • Hero Member
  • *****
  • Karma: 18
  • Posts: 556
    • http://www.hbw-webdesign.nl/
'Excluding' Directory
« Reply #22 on: December 02, 2006, 04:12:10 pm »

OK Tim I see what's going wrong. I may be was not clear enough.

1. make a seperate .htaccess file with only this line:
Code: [Select]
Redirect permanent / http://www.youdomain/snews/and place it in the root of your site.

2. remove the last line of the .htaccess file of sNews.

3. place the .htaccess file of sNews in the sNews-folder.

It shlould look like this:

- root
     .htaccess  (the one line file)
    +++wordpress
             wordpress files and folders
    +++snews
             .htaccess  (the .htaccess file that comes with the sNews zipfile)
             index.php
               and the rest of the sNews-files and folders.

This should do the trick, Tim.

Btw. Wordpress doesn't has the need of a .htaccess file
Logged
Confidence is reduced complexity.
brauck.nl for free css templates

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #23 on: December 02, 2006, 04:19:40 pm »

Thanks for the clarification Brauck - I can see how that would work.

Unfortunately, I still get the error I mentioned in an earlier post which does this:

http://www.timrowe.co.uk/snews/snews/snews/snews/

Yikes!


Best,
Tim
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • I'm a self-made man and worships my creator.
    • p-ahlqvist.com
'Excluding' Directory
« Reply #24 on: December 02, 2006, 04:30:38 pm »

Ok, but I guess this is b'cause you don't have the folders in the order Brauck describes, perhaps...

Correct me if I'm wrong, but your  structure is like this:

-rrrrroot
        sNews (AT the root)
        1. .htaccess  (the one line file)
        2. .htaccess  (the .htaccess file that comes with the sNews zipfile)
        3. index.php
        4. and the rest of the sNews-files and folders
        +++ wordpress
                1. wordpress files and folders

So Braucks solution will not work, right. Have you tried to shorten the one line .htaccess ? I don't know if it would make a differance or even if it's correct in any way ;)... but as you have the one line .htaccess saying:

Redirect permanent / http://www.youdomain/snews/

You're sort of telling with the .htaccess that there is in fact a snews folder on the site... Try and remove that last /snews/ and just see wh'appens ;)

Patric.

PS. I don't know if it works having TWO .htaccess at the same level, might wanna consider Braucks folder structure after all ;)... Or trying to add the one line snippet into the snews .htaccess file like you had before but with the differance - no /snews/ in the Redirect permanent... DS.
Logged
"It's only dead fish that goes with the flow... "
Updated

brauck

  • Hero Member
  • *****
  • Karma: 18
  • Posts: 556
    • http://www.hbw-webdesign.nl/
'Excluding' Directory
« Reply #25 on: December 02, 2006, 04:39:32 pm »

Tim,

I tested it on my local server and it was doing ok.

I will try to test it tomorrow on my live server and let you know what happened.

In the meantime maybe bram will drop by; he defenitly has the solution :)
Logged
Confidence is reduced complexity.
brauck.nl for free css templates

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #26 on: December 02, 2006, 04:42:21 pm »

I really appreciate your efforts, Brauck.

Thanks,
Tim
Logged

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #27 on: December 02, 2006, 04:44:55 pm »

Hi Patric,

I definitely have my directory and file structure set up as illustrated by Brauch's tree.

I've tried various permutations of the statement (including just my sites URL with th no 'snews' directory appended) and just get the Firefox error msg.

Chhers,
Tim
Logged

Patric Ahlqvist

  • Nobodys perfect, but Im pretty effing close
  • ULTIMATE member
  • ******
  • Karma: 65
  • Posts: 4867
  • I'm a self-made man and worships my creator.
    • p-ahlqvist.com
'Excluding' Directory
« Reply #28 on: December 02, 2006, 04:54:27 pm »

Quote from: haelen
I definitely have my directory and file structure set up as illustrated by Brauch's tree.
Then I don't quite understand. At the bottom of this post: http://www.solucija.com/forum/viewtopic.php?pid=17932#p17932 you say that "you don't want to take my sNews installation away from the root directory" which I understand meaning that you have your snews directly at the root, NOT in its own folder - Is this assumption wrong ?

Anyways. I'd better stay out of discussions when I don't know what I'm talking about, right :lol: I do more harm than use, hehe...

Patric.
Logged
"It's only dead fish that goes with the flow... "
Updated

haelen

  • Jr. Member
  • **
  • Karma: 0
  • Posts: 62
'Excluding' Directory
« Reply #29 on: December 02, 2006, 05:18:07 pm »

Quote from: Patric
you say that "you don't want to take my sNews installation away from the root directory" which I understand meaning that you have your snews directly at the root, NOT in its own folder - Is this assumption wrong ?
What I meant was, as sNews *is* the basis for my site, I didn't want people to have to go to another directory other than 'root' to get there.

Now that I see that it *can* reside in its own dir. - no problem.

Quote from: Patric
Anyways. I'd better stay out of discussions when I don't know what I'm talking about, right :lol: I do more harm than use, hehe...
No. We all learn from one another *and* our (my) mistakes :)

Now, time for a break (and a beer!) :)

Best,
Tim
Logged
Pages: 1 [2] 3