51 (edited by Jérémie 2005-03-05 11:34)

Re: Feedback wanted on URL rewriting thing

I've done a clean install to test it. The basics seems to works fine, but some peripherals don't (including anything search related). Anyway, it looks promising.

Trying to figure out where to report bug ^^

52 (edited by Romuald 2005-03-05 20:11)

Re: Feedback wanted on URL rewriting thing

It works for me, all the links are good.
Only the "Jump To" send not clean URL.

I've update 1.2.2 to 1.3 with svn.

// edit:

I've modified the .htaccess at line 54
#RewriteRule ^users/([0-9\-]+)/([a-z_]+)/([a-zA-Z]+)/(.*?)/page/([0-9]+)/?$ userlist.php?show_group=$1&sort_by=$2&sort_dir=$3&username=$4&p=$5 [L,NC]

It generate 500 error. (on apache 1.3.27)

Sorry for my french english.
GT4 Club driver France & Forum - Lingerie.

Re: Feedback wanted on URL rewriting thing

Jeremie: Report any bugs related to this in this topic.

Romuald: Hmm, that's odd regarding the RewriteRul generating a 500. It works perfectly fine in apache2.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

54

Re: Feedback wanted on URL rewriting thing

I tested this as much as time allowed over the weekend, and everything worked flawlessly. I'll do more testing this week, in anticipation of launching the first site based on 1.3dev on Monday. smile

My only suggestion at the moment would be to change the name of the .htaccess file in the archive. On Mac OS X and other *nix-based systems, the .htaccess file is invisible and thus does not appear to be included in the distribution. One potential solution to this problem might be to name it "apache.conf" and then tell folks that they need to change it to ".htaccess" before/after uploading it to the server.

The reason I suggested "apache.conf" instead of, say, "htaccess" is that .htaccess files are only needed in shared hosting environments where you don't have access to the httpd.conf file itself. While many folks use shared hosting, many others run their own servers. As per Apache's recommendation, .htaccess files should only be used when you don't have the ability to simply insert the relevant directives directly into the httpd.conf file itself.

Once again, fantastic work, Rickard! big_smile

Re: Feedback wanted on URL rewriting thing

Nice to hear it's working out. I will look into the quick jump problem Romuald mentioned.

Justin: The problem with renaming the .htaccess file is that on windows, you can't name a file .htaccess. This means people will have to upload it and then rename it on the server. Hmm.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

56 (edited by Jérémie 2005-03-09 01:18)

Re: Feedback wanted on URL rewriting thing

Ok I will re-install it and report here. Trying to figure out where to test it, most of my host have root rewrites rules already...

Ok i can confirm that Apache 1.x doesn't like the htaccess at all. Same issue with same rule as Romuald.

Re: Feedback wanted on URL rewriting thing

Rickard, look at the <base> tag.

58 (edited by Jérémie 2005-03-09 01:25)

Re: Feedback wanted on URL rewriting thing

Rev117.

Incorrect redirection : after posting a new thread, it looks for post/2/#p2 and report "Bad request. The link you followed is incorrect or outdated."

Search: all the quick links to search (show your post, and the like) send to the correct clean url but show the search page, with nothing special.

59

Re: Feedback wanted on URL rewriting thing

Rickard wrote:

The problem with renaming the .htaccess file is that on windows, you can't name a file .htaccess.

Mac OS X works the same way -- you can't create a file that starts with a period unless you're comfortable with a command line. The standard GUI procedure here is just as you suggested: upload the file and then rename it on the server. I don't think too many people will have trouble renaming the file on the server end, as every FTP client I've ever seen can rename files in a snap.

That said, I see no harm in providing the information in more than one place. In addition to the .htaccess file, why not also include the needed directives in the readme/install docs? That way, non-Windows folks can simply copy and paste the directives into httpd.conf or an .htaccess file as needed.

Re: Feedback wanted on URL rewriting thing

Bwongar.com wrote:

Rickard, look at the <base> tag.

What about it? I'm using it already.

Jérémie wrote:

Rev117.

Incorrect redirection : after posting a new thread, it looks for post/2/#p2 and report "Bad request. The link you followed is incorrect or outdated."

Search: all the quick links to search (show your post, and the like) send to the correct clean url but show the search page, with nothing special.

Odd. I will look into it.

Justin wrote:

Mac OS X works the same way -- you can't create a file that starts with a period unless you're comfortable with a command line. The standard GUI procedure here is just as you suggested: upload the file and then rename it on the server. I don't think too many people will have trouble renaming the file on the server end, as every FTP client I've ever seen can rename files in a snap.

That said, I see no harm in providing the information in more than one place. In addition to the .htaccess file, why not also include the needed directives in the readme/install docs? That way, non-Windows folks can simply copy and paste the directives into httpd.conf or an .htaccess file as needed.

I see your point. I just don't like having stuff in two places. It means I have to remember to update them both whenever I change something.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

61

Re: Feedback wanted on URL rewriting thing

I agree that having everything in one place would be nice. In that case, however, I would recommend changing the file name in the distribution. If the Apache directives remain solely contained in a file named ".htaccess", the likely result will be a lot of very confused and frustrated non-Windows users.

62 (edited by Jérémie 2005-03-09 16:53)

Re: Feedback wanted on URL rewriting thing

Since you have to manipulate the .htaccess file anyway (moving it to the root of PunBB installation), you could change it's name, for htaccess (no dot) for example.

Re: Feedback wanted on URL rewriting thing

but you can't rename it to that in windows

Re: Feedback wanted on URL rewriting thing

Hello. Just registered, I've been watching this topic for a while and now I just couldn't resist to post. smile

Connorhd wrote:

but you can't rename it to that in windows

You actually can rename files to names with a leading dot in Windows, using the DOS command line. The command is ren.

ren foo .htaccess

Re: Feedback wanted on URL rewriting thing

who uses a command prompt to rename files? its just not gonna happen

Re: Feedback wanted on URL rewriting thing

Even though it causes some problems for people running windows, I think Jérémie is right. I'll rename it. The question is to what smile

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Feedback wanted on URL rewriting thing

example.htaccess

Re: Feedback wanted on URL rewriting thing

But it's not really an example, is it?

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Feedback wanted on URL rewriting thing

Well, I'm using it myself for my local web server and I did not encounter any problems yet.
Mh, why not make PunBB create an .htaccess itself? Wordpress is doing that afaik.

Re: Feedback wanted on URL rewriting thing

coaster: Because PunBB won't allow you to configure your own rewriting scheme. Also, it would require PHP to have write permissions to .htaccess in the web root.

"Programming is like sex: one mistake and you have to support it for the rest of your life."

Re: Feedback wanted on URL rewriting thing

Rickard wrote:

coaster: Because PunBB won't allow you to configure your own rewriting scheme.

Uhhh... and what about localization of the scheme ?

72

Re: Feedback wanted on URL rewriting thing

As to what to rename the file, something along the lines of "Apache-Directives.conf" would probably be the most accurate. As noted above, these directives should go into the httpd.conf file provided the site admin has write access to it. If not, then the user should upload the directives to the server and rename it .htaccess. There are several reasons why httpd.conf is preferable to .htaccess files, the most important of which is performance. If .htaccess overrides are enabled, Apache has to look for them in each and every directory, thereby increasing CPU load.

coaster: WordPress will only create the .htaccess file if the web server process has write access to the relevant directory, which for many people may not be the best arrangement from a security perspective. Of course the user could create an empty .htaccess file, give it the correct permissions, and then let WordPress edit it, but in that scenario you might as well just have the user paste the directives at the same time they are going to the trouble of creating an empty .htaccess file.

Just my two cents... smile

Re: Feedback wanted on URL rewriting thing

Jérémie wrote:
Rickard wrote:

coaster: Because PunBB won't allow you to configure your own rewriting scheme.

Uhhh... and what about localization of the scheme ?

You do that by editing the rewrite rules by hand. You have to know how Wordpress works in order to understand what I meant smile

"Programming is like sex: one mistake and you have to support it for the rest of your life."

74

Re: Feedback wanted on URL rewriting thing

Question: Are search engine friendly URL's also spammer friendly URL's i.e. spammers will find the threads more easily.

75

Re: Feedback wanted on URL rewriting thing

No real proof, but we've definitely noticed an increase in spammers since moving to the pretty URLs.

Hard work may not kill you, but why take chances?