Giter VIP home page Giter VIP logo

seo-friendly-url's People

Contributors

dottech avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

seo-friendly-url's Issues

Resolvable Items are not always children of StartItem

Hi Ruud,

first of all, thank you for the great module. I've discovered a problem with the use of your module.
In your resolver you go on the assumption that all resolvable Items must be below the StartItem.
This is also reflected in your ItemResolver code.

The HttpRequestArgs args.Url.ItemPath property is by default composed of RootPath + StartItem + LocalPath.
The method ResolveItem is thus always called with StartItem in the path parameter.

The Problem is that in my current project all resolvable items are siblings of StartItem and not children.

To make your ItemResolver more generic, it requires a handling which calls the method ResolveItem with different or customized parameter values, when variable resolved equals null.

Btw, In Sitecore.Pipelines.HttpRequest.ItemResolver the handling of various ItemsPath is also implemented.

Right now I have the problem solved as follows: (ItemResolver.cs:107)

// Resolve the item with security disabled.
// Security will be applied after an item has been resolved.
using (new SecurityDisabler())
{
  resolved = ResolveItem(args.Url.ItemPath) ?? ResolveItem(Context.Site.RootPath + args.LocalPath);
}

You know what I mean? Maybe you can implement the better.

Many greetings
Maik

Aliases not working

When the property forceFriendlyUrl is set to true, the site alises are disabled, it would be nice to have aliases without a redirect when we want an alias for an item

Allow trailing slashes in URL

Hey Ruud. This module is great. It's the best solution I've seen so far for taking care of URL's in Sitecore.

So far I've used it on one Sitecore implementation but I had to make a small change in the code to allow URL's to accept trailing slashes.

ItemResolver.cs - Line 72

I changed the current line:
string[] itemNames = path.Split('/');

To this instead:
string[] itemNames = path.Split(new[] { '/' }, StringSplitOptions.RemoveEmptyEntries);

This was important when migrating from sites that were previously on WordPress since their URL structure usually has trailing slashes.

Thanks!

infinite redirect loop scenario

  1. set languageEmbedding="always"
  2. go to your site and try to access content outside of your site

An example might be:
http://demosite/sitecore/content/home (assuming you still have the home node from the base install)

This will cause the module to constantly loop between

http://demosite/en/sitecore/content/home?sc_lang=en
and
http://demosite/sitecore/content/home?sc_lang=en

It just keeps swapping between the two until the browser throws up

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.