RIPC: Remove Index.Php Completely From URL for SEO

Started by Hj Ahmad Rasyid Hj Ismail, August 20, 2010, 04:01:10 AM

Previous topic - Next topic

InfoStrides

Quote from: ahrasis on December 09, 2011, 11:05:47 PM
It is in the OP or uninstall it.

What do you mean by OP? I already uninstall it.

Hj Ahmad Rasyid Hj Ismail

Updated. New version will only remove index.php in your forum url in three places only  i.e. in your forum name or image link, home menu button link and top linktree link. It should not have any problems with other mods except to some themes.

To update, remove old/previous version. Then install this new one.

Hj Ahmad Rasyid Hj Ismail

Quote from: The Burglar! on October 18, 2011, 04:24:23 PM

$scripturl = $boardurl . preg_replace('/index.php','?');

Implemented with thanks to your suggestion and improvement for this mod.

weerforum

#43
Works perfect Ahmad Rasyid Ismail

Thnx  :D ;) ;D

Edit.......not working when i go to a board i see a white page

Herman's Mixen

This mod is developed to work with the Forums not to use with the SimpelPortal you use ;)
SimpelPortal needs some extra modification to work with this.

Quote from: Ahmad Rasyid Ismail on December 21, 2012, 04:42:12 AM
Implemented with thanks to your suggestion and improvement for this mod.

Nice too see that be welcome ;)
Met vriendelijke groet, The Burglar!

 House Mixes | Mixcloud | Any Intelligent fool can make things bigger, more complex, and more violent.
It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Albert Einstein

Former Godfather of our dutch community ;)

weerforum


Chris180

H.ARIS,

Thanks for making this mod.

The links provided both just link to ahrasis (dot com)

They dont point to a download. I am been searching that website you linked and it seems to have nothing to do with smf mods. Any help appreciated on this as I would like the remove the index.php to make my forums look more user friendly and tidy. I am using a custom skin so I can't follow the manual fix.

Arantor


Chris180

Woops, I was clicking on the wrong link :-S. I managed to install it, however the first one works, the second one (remove 3 links) doesn't work :(.

All I get now is - forumname/index.php?PHPSESSID=c1be342afdd5458376b2f089770b88af;wwwRedirect

no worries because the first one does the trick, but I just wanted to point out the remove 3 links one doesn't work.

Arantor

The second mod removes them from the three places it claims to do so.

Except the first mod does actually have bugs and I wouldn't be surprised if your error log is flooded with errors because the preg_replace expression is invalid.

Chris180

Agh, I installed it and now I can't log into my admin area. What can I do? I just type in my password and nothing happens.  >:(

I'm sort of stuck right now, is there a way to manually remove this? Any ideas? Thanks. I removed the package from the packages folder but that did nothing. At least I think it's this mode because the forum was working fine before, and this is the only thing I have done to it today and now I can't log in.

edit: Just cleared my browser and now I can't even log in to my account.

Arantor

Removing it from the packages folder just made it impossible to use the package manager to uninstall.

Manual uninstallation is simply reversing the install instructions - it's a one line change, just do this in reverse: http://custom.simplemachines.org/mods/index.php?action=parse;mod=2709;attach=214323;smf_version=2.0.3

Chris180

Quote from: Sir Cumber-Patcher on January 08, 2014, 02:27:31 PM
Removing it from the packages folder just made it impossible to use the package manager to uninstall.

Manual uninstallation is simply reversing the install instructions - it's a one line change, just do this in reverse: http://custom.simplemachines.org/mods/index.php?action=parse;mod=2709;attach=214323;smf_version=2.0.3

Thanks so much, that worked, you are amazing :). I'll re-try the 3 link url package again if you say it works then I believe you :).

Arantor

It does the job it claims to do, nothing more, but what you want isn't what it does. Doing what you want will cause trouble within the way SMF is constructed (and that isn't going to change in 2.x)

Chris180

Quote from: Sir Cumber-Patcher on January 08, 2014, 02:31:12 PM
It does the job it claims to do, nothing more, but what you want isn't what it does. Doing what you want will cause trouble within the way SMF is constructed (and that isn't going to change in 2.x)

hmm, well there isn't a single smf forum I have seen yet that has the .index.php trail (except this one), so it surely can be done safely? It's so annoying.

I installed the 3 link package and now when I go to my forum instead of index.php I now get index.php?wwwRedirect

Are you sure you have tested it recently on the latest version? Because this is what i'm getting with this package :(.

Arantor

Except every single forum in the base package does it, with plenty of good reasons.

The wwwRedirect is because the forum is configured to use www in the address but you tried to access it without www in the address (or vice versa, it's configured not to but you used it)

I didn't even have to test it, I can see from the code that it's physically invalid even before I attempt to install it, but I also know exactly what's changed in SMF over the years with respect to how URL detection works. I'm not carrying a Developer badge for nothing ;)

It's simply not safe to do in SMF because of how SMF handles certain things, namely session reinjection for search engines.

Chris180

Ok thanks for the explanation :). I hope such thing could be possible in the future, but for now I would rather have the latest software installed with the index trail over a base package without it :). Not too big of a deal I guess, I am just a bit OCD with these things.

Hj Ahmad Rasyid Hj Ismail

Quote from: Chris180 on January 08, 2014, 03:02:43 PM
Ok thanks for the explanation :). I hope such thing could be possible in the future, but for now I would rather have the latest software installed with the index trail over a base package without it :). Not too big of a deal I guess, I am just a bit OCD with these things.

Yes. This mod is actually no big deal. It was a matter of packaging a simple tip and trick that worked in the past but failed to work properly after SMF has further developed.

I have returned to find the best way to accommodate this and find that the only easiest way to this is via htaccess rewrite. As such, I have learned and developed a new approach to install the said working code into your current htaccess file.

I have tested to be working on both SMF version 1.1.x and 2.0.x.

Though it will depends on each individual forum server, all I can say is, it finally works in SMF.

Thank you for all responses and feedbacks. You may now download and enjoy the latest RIPC for all versions in the mod page.

Arantor

So are you going to edit the PHPSESSID injector this time?

Kindred

I will also post a note here:  We have ended up having to provide support to a bunch of site that seem to think thise was a good idea (note, it is not)

While it may seem to work with a basic installation (although Aranator's comments suggest that even that will have issues)
MANY other mods will fail if you are using this...     and quite honestly, it serves no useful purpose, really...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Advertisement: