NP_LMFancierURL v3.0.2 - Search engine optimized URLs

Post your new plugins here!
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

NP_LMFancierURL v3.0.2 - Search engine optimized URLs

Postby slightlysome » Mon Feb 28, 2011 4:20 am

The NP_LMFancierURL plugin provides the posibility to use search engine optimized URLs for a Nucleus CMS blog site. A URL friendly version of each blog name, member name, item title, category name and extra skin name is generated by the plugin. These URL friendly values are then used when the URL for blogs, members, categories, items and extra skin is parsed or generated. These values can be edited by the blog administrator or the site super administrator.

This plugin was originally made to replace the NP_FancierURL2 plugin that have several bugs and problems. Version 2 of the NP_LMFancierURL plugin was rewritten from scratch to be able to include the new version 2 features.

The plugin offers 3 different URL schemes. What URL scheme to use can be configured globaly for the site or for each blog.

Available URL schemes are:
  • Fancier - This is the old URL scheme used in NP_FancierURL2. URLs are build up with a keyword/value structure. The keywords and values used are editable. Example: www.example.com/blog/myblog/item/an-item-title
  • Compact - This is a new URL scheme introduced in version 2 of NP_FancierURL plugin. It's like Fancier URL scheme, but drops the keywords from the URL. The makes the URL more compact. The values used are editable. Example: www.example.com/myblog/an-item-title
  • Classic - This is simmular to the URL scheme you get when you activate FancyURL in Nucleus configuration, but don't install a FancyURL plugin. URLs will be build up as with the Fancier URL scheme, but will use interal id numbers instead of text values. The keywords used are editable. Example: www.example.com/blog/1/item/53
In addition to the 3 URL schemes is it possible to use freeform item URL parts. With freeform URL parts can you enter the URL part that you want to use to identify an item in a blog. Unlike normal URL parts can a freeform item URL part consist of one or more / character. With this you can simulate directory structures more freely with freeform item URL than with normal URL parts. Templates can be used to automatically generate freeform item URL parts from the item data.

In version 3 of the plugin was custom base URLs introduced. With this functionality can you make the different blogs in a Nucleus installation have different domains and/or Nucleus directories. It is also possible to set the custom base URL for a blog to also identify the blog. With this option set will not a blog URL part be needed in the URL to any pages in the blog.

For a download link and the full information on the plugin see the NP_LMFancierURL plugin page.

The NP_LMFancierURL plugin is dependent of the NP_LMURLParts plugin for URL part handling. For a download link and the full information on the NP_LMURLParts plugin see the NP_LMURLParts plugin page.
Last edited by slightlysome on Sat Feb 15, 2014 6:23 pm, edited 9 times in total.
- Leo -
LMNucleus CMS home page: nucleus.slightlysome.net
My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com
My Nucleus plugins.
User avatar
Imajica
Posts: 129
Joined: Sat Feb 06, 2010 11:52 pm
Location: Racine WI USA
Contact:

Postby Imajica » Sat Mar 19, 2011 4:53 pm

I think I'm going to take the dive and try this one today
User avatar
Imajica
Posts: 129
Joined: Sat Feb 06, 2010 11:52 pm
Location: Racine WI USA
Contact:

Postby Imajica » Sat Mar 19, 2011 9:51 pm

very much liking the Custom Fancy URL keywords

$CONF['ItemKey'] = 'item';
$CONF['ArchiveKey'] = 'archive';
$CONF['ArchivesKey'] = 'archives';
$CONF['MemberKey'] = 'member';
$CONF['BlogKey'] = 'blog';
$CONF['CategoryKey'] = 'category';
$CONF['SpecialskinKey'] = 'special';
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Tue Jun 28, 2011 12:05 am

Version 2.0 of the NP_LMFancierURL plugin is now released. Updated first post with new plugin description and version changes.

See my plugin page for full description and download link.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
matt_t_hat
Posts: 1123
Joined: Sun Aug 21, 2005 4:45 pm
Location: UK
Contact:

Postby matt_t_hat » Fri Jul 01, 2011 12:40 am

Bother I just spent an hour adding features to version 1.0 and here is version 2.0... nuts.

In the morning I'll see if I can port my changes and then share them.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Fri Jul 01, 2011 1:58 am

I did say some months ago I was working on v2. :)
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
matt_t_hat
Posts: 1123
Joined: Sun Aug 21, 2005 4:45 pm
Location: UK
Contact:

Postby matt_t_hat » Fri Jul 01, 2011 9:44 am

slightlysome wrote:I did say some months ago I was working on v2. :)
That's what I get for not visiting the forums for a few months. :( My own fault I guess.

The only feature I need is to automatically add a three digit number to each URL. The reason being is that Google news is super fussy about URL format. In my (now totally pointless) edit of v1 I used a zero padded version of the item id. I would also need to lock the URL in place once the post was published as Google News also dislikes URLs that change. I think your helper plugin does this so maybe I can write something that depends on v2 and the helper.

I was very impressed with the handling of categories which had always bugged me. Also pleased that you didn't use addslashes for v2. Very good sir.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Fri Jul 01, 2011 1:23 pm

It should possible to add an option to automatically add a 3 digit number (that could be the 3 last digits in the item id) when generating the URL part for an item. And an option to automatically lock the URL parts for new items. (Now the locking has to be done manually on the LMURLPart admin page.)

As the LMFancierURL plugin is now, you can only have a single URL part that identify an item, like /item/this-is-an-item-title, and you can't have an item URL that is like this: /item/this/is/an/item/title. To remedy this I'm have an idea of making it possible to set up free-form item URLs where the complete URL (and not a single part) is used to match the URL to an item. Perhaps with the possibility to set up templates (like yours) for automatically generating the free-form URL when an item is created.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
Captain_Caveman
Posts: 9
Joined: Sun May 27, 2007 9:23 pm

Postby Captain_Caveman » Thu Jul 14, 2011 5:25 am

I got a chance to migrate to the newer plugin and encountered some troubles during install. I am not sure if I did something wrong but thought I would document my experience to help either the developer or anyone else that encounters the same. I have only one blog on this site, am running v3.64, and uninstalled NP_FancierURL2 first.

I got version 2.0 from the offsite www.slightlysome.net. I unzipped everything and uploaded all to the nuclues/plugin directory. I went to the admin section of my blog and was able to install LMURLParts without incident. I then proceeded to install NP_LMFanierURL and the page went blank. I waited a considerable amount of time and hit reload. It gave me a message that any info would be resent blah blah, continue or stop. I continued and got a message that the plug in was already installed. Then when I went to my Management->Plugins page only one plugin (SkinFiles) showed on the table. Interestingly all my plugins were listed in the menu on the left side of the page, but only one showed in the table in the main area.

I thought that maybe I did not wait long enough, so I removed the lmfancierurl directory and the NP_LMFancierURL.php file from the nucleas/plugins directory, and when I went back to the Management->Plugins page all my plugins showed back up. The NP_LMFancierURL plugin showed up at the bottom as an error and I uninstalled it. I then re-uploaded the unzipped contents to my plugin directory and went through the same steps and waited longer once the page went blank during the install. After several minutes I hit the back key and only one plugin was showing again. So again I deleted the directory, deleted the php file, and then uninstalled to get back to a good state.

I then downloaded the 1.0 version of the plugin from the nucleus site. I was able to unzip, upload, and install without incident. I tried uninstalling version 1.0 and and installing version 2.0 again but got the same results as before. I have uninstalled version 2.0 and am currently running 1.0.

On a positive note NP_LMFancierURL version 1.0 did fix the problems I was having with NP_FancierURL2. I will periodically check back to see where my install went wrong or if/how others dealt with problem.
ftruscot
Nucleus Guru
Nucleus Guru
Posts: 7430
Joined: Wed Feb 22, 2006 6:19 pm
Location: Massachusetts
Contact:

Postby ftruscot » Thu Jul 14, 2011 6:43 am

The blank page after plugin install is due to a PHP error. Since the plugin presumably works for slightlysome, it is likely that the error is not syntax related, but likely is PHP version related. It will be helpful for slightlysome to know the PHP version of your site, as well as the text of any PHP errors in your web server error logs.
Is your question not solved yet?
Search our FAQ,
read the Documentation, or
browse the list of available plugins.

Check out my plugins
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Thu Jul 14, 2011 2:25 pm

Captain_Caveman wrote:I then proceeded to install NP_LMFanierURL and the page went blank.


I'm sorry that you had problems with installing NP_LMFancierURL. The plugin is installing and running fine on my site with PHP version 5.2.6 (Debian 5.0).

As fruscot said I would need the PHP error messages and the PHP version number of your site to be able investigate your problem.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
Captain_Caveman
Posts: 9
Joined: Sun May 27, 2007 9:23 pm

Postby Captain_Caveman » Fri Jul 15, 2011 4:09 am

Excellent. Thank you ftruscot and slightlysome for your help. You are indeed correct that I am running with the wrong version of php. I guess I will finally have to get around to installing the required version of php that is required for the version of nucleus I am running.

This problem was my fault and I appreciate your helping me troubleshoot it. I hope that my detailed description will help someone that falls into the same pitfall I did. My bad. I am always impressed by the top notch support I find in these forums. Thank you.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Fri Jul 15, 2011 1:44 pm

Captain_Caveman wrote:You are indeed correct that I am running with the wrong version of php. I guess I will finally have to get around to installing the required version of php that is required for the version of nucleus I am running.


I would like to have my plugin work with all recent versions PHP, so if you can provide the version of PHP on your web server and any PHP error from the web server log I may be able to make the changes needed to get the plugin to work on your version of PHP.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Sat Aug 06, 2011 3:22 pm

The v2.0.1 release of the NP_LMFancierURL plugin is now available. It contains the following changes from v2.0:
  • Fixed problem with identifying the used url scheme when parsing an url.
  • Super admin did not get an option to edit top level parts if the site only had one blog.
  • New error message when the edited urlpart is a valid number (not a legal urlpart).

The upgrade from v2.0 to v2.0.1 can be done by replacing the plugin files.

For a download link and the full information on the plugin see the NP_LMFancierURL plugin page or wiki page.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Sat Aug 27, 2011 2:10 pm

Version 2.1.0 of the NP_LMFancierURL plugin has been released. New in this version of the plugin are freeform item URL parts.

With freeform item URL parts can you enter the URL part that you want to use to identify an item in a blog. Unlike normal URL parts can a freeform item URL part consist of one or more / character. With this you can simulate directory structures more freely with freeform item URL than with normal URL parts. Templates can be used to automatically generate freeform item URL parts from the item data.

For a download link and the full information on the plugin see the NP_LMFancierURL plugin page or wiki page.

The NP_LMURLParts plugin is no longer distributed together with NP_LMURLParts. The latest version of the NP_LMURLParts plugin should handle missing mbstring PHP extension which gave the blank page on the LMFancierURL installation for some.

For a download link and the full information on the NP_LMURLParts plugin see the NP_LMURLParts plugin page or wiki page.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Sat Aug 27, 2011 2:36 pm

Captain_Caveman wrote:I will periodically check back to see where my install went wrong or if/how others dealt with problem.


The new release of NP_LMFancierURL and NP_LMURLParts should fix your problem with installing v2.0 of NP_LMFancierURL.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
User avatar
matt_t_hat
Posts: 1123
Joined: Sun Aug 21, 2005 4:45 pm
Location: UK
Contact:

I have a question regarding special skin parts.

Postby matt_t_hat » Tue Sep 13, 2011 1:12 pm

I have a question regarding special skin parts.

I'm not sure if it is me being blind or something else.

I am setting things up for http://ThanetNewsNetwork.co.uk (the news site I have spoken of before). I created a special skin called Thankyou which contains a thank you to donation makers to the project.

Now I expected that the URL would be ThanetNewsNetwork.co.uk/special/Thankyou but this is 404. I checked URL Parts and the special skin is still "special" so I am wondering what I have done wrong.
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Tue Sep 13, 2011 1:31 pm

matt_t_hat wrote:Now I expected that the URL would be ThanetNewsNetwork.co.uk/special/Thankyou but this is 404. I checked URL Parts and the special skin is still "special" so I am wondering what I have done wrong.


This may be the problem:
plugin help wrote:Because of a shortcoming in the Nuclues core can the plugin not automatically catch extra skin parts that are added to a skin after the plugin is installed. When you add an extra skin part to a skin, must you go to the blog settings and save on each blog that uses the skin.


Otherwise you may check what urlpart the special skin is listed with in the URLPart type "Special" section under your blog in LMURLParts.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.
ftruscot
Nucleus Guru
Nucleus Guru
Posts: 7430
Joined: Wed Feb 22, 2006 6:19 pm
Location: Massachusetts
Contact:

Postby ftruscot » Tue Sep 13, 2011 3:14 pm

There are events in the development trunk that will help here once 4.0 is released. Unfortunately, life has disrupted the momentum of that release for a few of us developers so it's slower going than it had been earlier in the year. I'll ping the developers and figure out where we are again for a release estimate.

For now, slightlysome, you might consider something like an "Update Subscriptions" button on the admin page for the plugin that would search for new skin parts and update you database?
Is your question not solved yet?

Search our FAQ,

read the Documentation, or

browse the list of available plugins.



Check out my plugins
User avatar
slightlysome
Posts: 213
Joined: Thu Feb 24, 2011 1:33 am
Contact:

Postby slightlysome » Wed Sep 14, 2011 12:51 pm

ftruscot wrote:For now, slightlysome, you might consider something like an "Update Subscriptions" button on the admin page for the plugin that would search for new skin parts and update you database?


The plugin already have a function on the plugin admin page that rebuild the complete database, but having a function that only rebuild the special skin part urlparts is a good idea.

But one still have the problem of knowing that this function should be used after you have added special skin parts.
- Leo -

LMNucleus CMS home page: nucleus.slightlysome.net

My Nucleus powered blogs: www.slightlysome.net - www.tswtraveler.com

My Nucleus plugins.

Return to “Plugin Development”