News:

SMF 2.1.6 has been released! Take it for a spin! Read more.

Main Menu

Pretty URLs

Started by SMFHacks.com Team, January 31, 2007, 10:56:43 AM

Previous topic - Next topic

L'AltroWeb

#1780
A new questions: i have test to rename a topic (with a very long title): http://darkwolf.altervista.org/forum/modemrouter/g604t-con-rtech_mod_3-6-0d_20070613_2-30-(20070613233015)-domanda-di-rete/
but url not update (also after maintenance).
How i can fix?

mark7144

I have SMF Arcade, is this mod working with that OK?

L'AltroWeb

#1782
Quote from: mark7144 on June 02, 2008, 09:56:33 AM
I have SMF Arcade, is this mod working with that OK?
see previos page.
Now in my site work fine (but actually don't rewrite Arcade Url)
-
@Dannii:
I have edit my Subs-PrettyUrls.php like this:
// Build the new .htaccess file
$htaccess = '# Pretty URLs mod
# http://code.google.com/p/prettyurls/
# .htaccess file generated automatically on: ' . date('F j, Y, G:i') . '

# Favicon
AddType image/x-icon .ico

RewriteEngine on
RewriteBase /forum

# Rules for: sitemap
RewriteRule ^smf_sitemap.php$ /forum/index.php?action=sitemap
RewriteRule ^smf_sitemap.xml$ /forum/index.php?action=sitemap;xml';

ksort($rewrites);
.......

In your opinion is correct or is best to use [L,QSA] rules?

Dannii

Quote from: Harvest on June 02, 2008, 09:29:18 AMDannii could You share with us how is the pretty_action_array addressed, I mean how to add some custom actions to the rewrite module ?
The array is updated whenever you run maintenance.

Quote from: Dark-Wolf on June 02, 2008, 09:46:33 AMA new questions: i have test to rename a topic (with a very long title): http://darkwolf.altervista.org/forum/modemrouter/g604t-con-rtech_mod_3-6-0d_20070613_2-30-(20070613233015)-domanda-di-rete/
but url not update (also after maintenance).
How i can fix?
Well they're not supposed to change, but if you really want to you can change it in the pretty_topic_urls table. Remember to drop the cache table/run maintenance too.

Quote from: mark7144 on June 02, 2008, 09:56:33 AMI have SMF Arcade, is this mod working with that OK?
Yes it should be fine. I think there was just a problem with one of the games Dark-Wolf had.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

Harvest

Quote from: Dannii on June 02, 2008, 10:15:47 AM
Quote from: Harvest on June 02, 2008, 09:29:18 AMDannii could You share with us how is the pretty_action_array addressed, I mean how to add some custom actions to the rewrite module ?
The array is updated whenever you run maintenance.


oh stupid me. I ran maintenance and somehow oversaw the change ;)  Sorry  :/

L'AltroWeb

#1785
Quote from: Dannii on June 02, 2008, 10:15:47 AM
Quote from: Dark-Wolf on June 02, 2008, 09:46:33 AMA new questions: i have test to rename a topic (with a very long title): http://darkwolf.altervista.org/forum/modemrouter/g604t-con-rtech_mod_3-6-0d_20070613_2-30-(20070613233015)-domanda-di-rete/
but url not update (also after maintenance).
How i can fix?
Well they're not supposed to change, but if you really want to you can change it in the pretty_topic_urls table. Remember to drop the cache table/run maintenance too.
mmm... ok.
The problem is that same user send really strange topic title and is very good if i can change.
Maybe you can provide to fix for future release?
PS i have edit precedent post, please can you see?
-
PPS: arcade problem is for all games, test this for example (make to click and lost) and test redirect.
http://darkwolf.altervista.org/forum/arcade/?sa=play;game=44

Dannii

QuoteIn your opinion is correct or is best to use [L,QSA] rules?
L stands for Last, so it would be a good idea to include it. QSA stands for Query String Append, again it's probably a good idea to include it.

Has the arcade code changed recently? Because I haven't had anyone report issues with it for months.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

L'AltroWeb

Quote from: Dannii on June 02, 2008, 10:35:41 AM
QuoteIn your opinion is correct or is best to use [L,QSA] rules?
L stands for Last, so it would be a good idea to include it. QSA stands for Query String Append, again it's probably a good idea to include it.
Ok now i test (in any case now work fine and after any maintenance my htaccess is ok ;))
Quote from: Dannii on June 02, 2008, 10:35:41 AM
Has the arcade code changed recently? Because I haven't had anyone report issues with it for months.
I use release 2.0.13 (last release).
I have test to change all relative url but none work.

Nao 尚

Quote from: Dannii on June 02, 2008, 10:35:41 AM
QuoteIn your opinion is correct or is best to use [L,QSA] rules?
L stands for Last, so it would be a good idea to include it. QSA stands for Query String Append, again it's probably a good idea to include it.
I believe it is only needed when your rewrite stuff has a query string by itself.

RewriteRule ^/(.*)$ index.php -> Calling /?test=yes would send back /index.php?test=yes (no QSA needed)
RewriteRule ^/(.*)$ index.php?works=not -> Calling /?test=yes would send back /index.php?works=not
RewriteRule ^/(.*)$ index.php?works=not [QSA] -> Calling /?test=yes would send back /index.php?works=not&test=yes


If I'm not mistaken...
I will not make any deals with you. I've resigned. I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.

Aeva Media rocks your life.

L'AltroWeb

#1789
Ok thanks, in any case work fine :)
PS: one questions: this is request url after submit a score in arcade: http://misyte.org/forum/arcade/index.php?action=arcade
maybe we can simply rewrite via htaccess to:
http://misyte.org/forum/index.php?action=arcade ?

Dannii

QuoteI believe it is only needed when your rewrite stuff has a query string by itself.
Hmmm I thought it was needed in all cases but you could be right. It doesn't really hurt anything to add it though.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

CraigPal

Is there a way to make the home button link to only
http://www.yoursite.com/  rather than
http://www.yoursite.com/index.php ?
I've tried a robot.txt with Disallow: /index.php but it blocks my Sitemap. Is there a way around this using a robots.txt command?

Thanks


Nao 尚

Quote from: Dannii on June 02, 2008, 09:42:23 PM
QuoteI believe it is only needed when your rewrite stuff has a query string by itself.
Hmmm I thought it was needed in all cases but you could be right. It doesn't really hurt anything to add it though.
I suppose it's only some minor extra work for the CPU.

Also, QSA will append "index.php" to the query string in some cases. Hence some very curious contents in the $_GET variable at one point, but no biggie really.

Raw> I think that's in QueryString.php...

$scripturl = $boardurl . '/index.php';

Just replace it with:

$scripturl = $boardurl;
I will not make any deals with you. I've resigned. I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.

Aeva Media rocks your life.

CraigPal


CraigPal

Quote from: Nao 尚 on June 03, 2008, 03:14:39 AM

Raw> I think that's in QueryString.php...

$scripturl = $boardurl . '/index.php';

Just replace it with:

$scripturl = $boardurl;

Sorry but that didn't work. The home buttons are still /index.php

Nao 尚

"Run Maintenance", maybe? :D
(I don't think it'll do the trick, but anyway...)
I will not make any deals with you. I've resigned. I will not be pushed, filed, stamped, indexed, briefed, debriefed or numbered.

Aeva Media rocks your life.

CraigPal

Quote from: Nao 尚 on June 03, 2008, 03:46:53 AM
"Run Maintenance", maybe? :D
(I don't think it'll do the trick, but anyway...)
No, that didn't work either.
Is there a way I can block search engines from using accessing the /index.php without blocking my Sitemap? The sitemap is the only thing I need to be available to the search engines.

Dannii

A sitemap is pointless if it's the only thing accessible to search engines.

Check your theme's index.template.php too, maybe the index.php is hardcoded in there.
"Never imagine yourself not to be otherwise than what it might appear to others that what you were or might have been was not otherwise than what you had been would have appeared to them to be otherwise."

CraigPal

Quote from: Dannii on June 03, 2008, 04:23:49 AM
A sitemap is pointless if it's the only thing accessible to search engines.

Check your theme's index.template.php too, maybe the index.php is hardcoded in there.
What I meant was the sitemap is the only thing that uses the index.php. The rest of my urls use the extensionless Pretty URLs exept for the index page - the "home" links within the forum.

I'll look for it in the theme's index.template.php too. Thanks

MultiformeIngegno

I've installed Pretty URLs on my SMF 2.0 Beta 3 Forum...
All the users, when they login, receive this error:

You were unable to login. Please check your cookie settings.

So they click "back" and they are logged on anyway...

The URL of the error is:
/profile/?pretty;action=login2&sa=check

How can I fix this?
Pheraps the problem is that i changed the forum URL from rockciclopedia.com/forum to forum.rockciclopedia.com and I manually edited the pretty urls table in the database ...
RockCiclopedia (wiki - forum), Tutta la storia del rock, scritta da voi ...
Rimanere aggiornati sul mondo della musica grazie al nuovo feed "RockCiclopedia Music News"!

Advertisement: