| | | |  |  | |  |
30.10.2004, 01:59
|
#1 (permalink)
| | Junior Mamber
Join Date: Jun 2004
Posts: 38
| gregmac's SEF .. not dead Yes, so I realize I said a few months ago that I'd finish up this component. Things got busy, as they have a way of doing, and I only finally just got around to doing this. I quickly checked out this other 404SEF component, which looks like it's built partly on my code or a similar concept. I considered just using it, but it doesn't quite work the way I want, and mine pretty much does, so what I'm currently working on is mostly the same code I had before, but with a few fixes and suggestions from the 404sef thread.
I'm starting a new thread for this, just to sort it out. I will post code later this weekend once I have things finished off, but just wanted to write to say what I have and get some preliminary feedback on it.. - SEF is all stored in the _sef table, as per the original release
- SEF url's are auto-generated at page creation time, and the table acts as a sort of a cache so if it exists already it doesn't have to look up all the item information (name, section etc).
- Entire solution is implemented as a component. I notice there is now a hook in mambo 4.5.1 for a com_sef component (which gets loaded instead of includes/sef.php) so I'm taking advantage of that. Downfall (?) is now this only works on 4.5.1 (fine I guess, since the original version works on 4.5.0)
- I have an administrative component for it. I looked at the redirector hack thing - not quite what I wanted though, so I just wrote one. At this point, it's about 70% done - just need to write the configuration options page, and make it installable (write an xml and put it in a .zip basically).
- All the options for controlling how the SEF creation works are in the administative interface. There's not many now, but I'll add a bunch as people need (or people can write me code to add as well).
- the interface also lets you create custom url strings (something I suggested in the original thread as a benefit of the db-based solution). Right now it requires the original mambo url, but I plan on making a drop-down type interface to select real components in Mambo.
- URLs are backwards compatible with the two other styles - namely, non-sef, and the normal mambo sef style.
- Everything is entirely based on the pathway. I don't really like the /section/category/title style (ie, regardless of if you even use the section for anything, or have it located in a different spot on your site). Whatever shows up as the pathway shows up as the URL.
- The url handles (i think) all of the international characters. It will be configurable to use any character as the spacer char.
- i'll add options for using pathway or not (the original flat style of just the name), title or title alias (and maybe "shorter of both").. any other requests?
- When it can't figure out a full SEF url, it uses partial's.. ie: "/Downloads/Some_Category/task,view_category/sort,asc/". I'm not entirely happy with this, but it's more of a problem with the way components work (ie
- don't put in task=view_category .. just use it as the default. the less junk in the url, the better). If anyone can think of an elegant way to solve this, let me know.
Thats all I can think of right now. I can't absolutely promise that I will get everything going this weekend, but I will certainly try very hard. At least by posting this I'll make myself look like an *** if I don't do it. I do need to update my company site to 4.5.1 before Monday, and it needs to run with this stuff - hence my new development.
Anyway, feedback welcomed - espesially from m2k. I'd really like to get something going between us but as I already had the majority of this code done (tho unreleased...) it made most sense for me to finish it off.
Last edited by gregmac; 03.11.2004 at 03:45.
Reason: title change
|
| |
30.10.2004, 21:12
|
#2 (permalink)
| | Elite Mamber
Join Date: Apr 2004 Location: /dev/peru/lima
Posts: 1,008
| Re: gregmac's SEF .. not dead Hi, i cant wait to give it a try, your original sef solution was good but had too many bugs, hope this one could a bit more "stable", good luck  |
| |
30.10.2004, 22:03
|
#3 (permalink)
| | Senior Mamber
Join Date: Sep 2004
Posts: 221
| Re: gregmac's SEF .. not dead Great news, welcome back!
Yes, 404 SEF does contain portions of your original code. My initial release credited both you and Travis for the inspiration. I have built from concepts of both and added some of my own. I really liked the database idea, it opens up so many options for creative urls. It was an awesome idea. I diverged from using the pathway exclusively simply because it was causing me so many problems. Instead, I started reading the info directly from mos_menu as I found it simpler for me than trying to decypher what pathway.php was really doing. It seemed convulted.
Anyway before rambling any further, I'll just stop now. I am open to colaberation. You can PM or email me if you wish with more details. I would certainly welcome the oppurtunity. |
| |
31.10.2004, 02:15
|
#4 (permalink)
| | Baby Mamber
Join Date: Oct 2004
Posts: 7
| Re: gregmac's SEF .. not dead That is a good idea!
we are waiting for your news |
| |
31.10.2004, 11:17
|
#5 (permalink)
| | Elite Mamber
Join Date: Apr 2004 Location: /dev/peru/lima
Posts: 1,008
| Re: gregmac's SEF .. not dead I could help too reporting bugs and such things  |
| |
01.11.2004, 10:07
|
#6 (permalink)
| | Junior Mamber
Join Date: Jun 2004
Posts: 38
| Re: gregmac's SEF .. not dead Well. I didn't quite make the weekend, but did get some stuff finished. In hindsight, probably shouldn't have tried to get the whole admin side going AND package it as an installable component, considering I'd never done either of those before.. but i digress..
The only thing that I know of now that purposfully doesn't work is the 'title' config option. Haven't implemented it. I've only done minor testing with pathway yes/no.. but it looks like it's working.
As always, feedback welcome. Everything is GPL, so of course send me changes/fixes/etc. http://www.gregmaclellan.com/com_sef_2.0b1.tar.gz |
| |
01.11.2004, 17:59
|
#7 (permalink)
| | Junior Mamber
Join Date: Jun 2004
Posts: 38
| Re: gregmac's SEF .. not dead You still have to enable sef in mambo..
but I did forget to post the .htaccess file (and include it in the installer..):
replace the two RewriteRule lines in your .htaccess with: Quote:
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*) /index.php/$1 [L]
| (the same as my original sef solution) |
| |
01.11.2004, 18:32
|
#8 (permalink)
| | Junior Mamber
Join Date: Apr 2004
Posts: 25
| Re: gregmac's SEF .. not dead Is thare any demo site? |
| |
01.11.2004, 19:29
|
#9 (permalink)
| | Junior Mamber
Join Date: Jun 2004
Posts: 38
| Re: gregmac's SEF .. not dead As of about an hour ago, my company site is running this in production. www.mwater.ca |
| |
01.11.2004, 20:53
|
#10 (permalink)
| | Junior Mamber
Join Date: Jun 2004
Posts: 25
| Re: gregmac's SEF .. not dead Hi Greg,
I installed your component and activated the .htaccess. The urls are displayed correctly but the target isn't found. Any hint?
Thanks. |
| | | Thread Tools | | | | Display Modes | Linear Mode |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is Off | | | All times are GMT +2. The time now is 08:35. | | | |