Skip to main content

Questions tagged [urls]

All questions related to Sitecore URL (item and media URLs) generation, configuration and its uses.

Filter by
Sorted by
Tagged with
0 votes
1 answer
61 views

Generate HrefLang tag in Sitecore XMC pages

We need to create hreflang tag for the pages added to the site. In the frontend, we are trying to build the page url for the current page. Is there any way, we can build the page url apart from window....
1 vote
1 answer
119 views

Issues while generating the media item url with space in item name

we have the below configuration with Sitecore 9.3 <encodeNameReplacements> <replace mode="on" find=" " replaceWith="-" /> </encodeNameReplacements> ...
0 votes
0 answers
35 views

How to catch error and redirect: A potentially dangerous Request.Path value was detected from the client (:)

When attempting to access URLs such as http://web.local/webpagehttp://web.local/webpage, we encounter issues and this error appears in the log: A potentially dangerous Request. Path value was detected ...
-1 votes
2 answers
7k views

Message: A potentially dangerous Request.Path value was detected from the client (>)

how to resolve this kind of issues? please help me > 30452 ERROR Application error. Exception: System.Web.HttpException > Message: A potentially dangerous Request.Path value was detected from > the ...
0 votes
3 answers
156 views

Media with aspx extension is not working

We have migrated to Sitecore 10.1 from Sitecore 8.7. In Sitecore 8, For-example, if the image location is /-/media/Project/Os-Theme/Styles/images/logo Then the following url returns the same image <...
0 votes
2 answers
240 views

Get complete url in HttpRequestProcessor

I want to get the complete URL in HttpRequestProcessor pipeline. When I hit https://www.abc.com/#section-1, currently args.RequestUrl is not returning the section path. How to get complete URL with ...
0 votes
1 answer
56 views

Shorturls being indexed under incorrect domains

I had a user bring up the fact that google was indexing www.domain1.com/shorturl1 correctly, but also www.domain2.com/shorturl1 (which points to the exact same content from the correct URL). After ...
1 vote
0 answers
35 views

Potentially dangerous Request.Path & illegal characters in path [duplicate]

I am trying to fix this "Potentially dangerous Request.Path" issue when URL contains characters like these - &, <, >, ! Basically, I need to redirect the page to 404. Ex: https://&...
4 votes
1 answer
3k views

Custom Item Url Builder

Im trying to implement a custom Url Builder with Sitecore 9.3.I can't seem to figure out how to patch it. I made a custom url builder that implements BaseUrlBuilder but when I try to patch it in I get:...
1 vote
1 answer
104 views

Error while instantiating agent random error

I'm using Sitecore 9.3, Suddenly I faced an error that causes the CM server to be down, and I'm not able to access it. I checked the logs and this is what I found: ERROR Error while instantiating ...
1 vote
2 answers
465 views

Sitemap generating random urls

I have an issue with the SXA sitemap where its rendering urls don't have an item in the site. When going the sitemap through {siteurl}/sitemap.xml it is containing records such as the below. Looking ...
0 votes
1 answer
776 views

Sitecore 9.3 CustomLinkProvider [duplicate]

There is a similar questions but sadly there's no help in there. I'm trying to create a CustomLinkProvider in Sitecore 9.3 and I have 2 problems: The LinkProvider() is Obsolete. What should I use ...
2 votes
1 answer
1k views

How to get URLS added in the Rich Text field and Link Manager Fields?

I want to redirect my urls added in the Rich Text Editor,General Links to custom urls on page load. To get the URLS which exist in the General Link field and in the Rich Text Editor, I am using the ...
1 vote
1 answer
2k views

Why is Display Name and the Item Name in the URL resolving to the same item

I have issue/concern where Sitecore is not returning a 404 response when the url contains the display name of the item. e.g. I have page called destination as a item name and display name as where,...
1 vote
0 answers
1k views

In MediaManager, how to get image's full url with specifed site's domain included?

The reason why I want to change the domain of an image url is because I'm providing an API to a third party. And the regulation is all media url and internal link url, needs to replace the default ...
2 votes
1 answer
3k views

Should targetHostName and hostName be the same?

In our Sitecore 9 setup we are using a CD and CM server. Currently, we have these config transformations: <sites env:require="TestCM" xdt:Transform="Insert"> <site name="website"> ...
3 votes
1 answer
2k views

Sitecore how to get an ImageField full url, not a relative path?

It's an Web API project, to provide some data for third parties. var image = new MediaItem(imageField.MediaItem); string src = Sitecore.StringUtil.EnsurePrefix('/', Sitecore.Resources.Media....
4 votes
1 answer
1k views

Getting an item using Powershell having only the URL

Is it possible to get a Sitecore item via Powershell script having only the public URL? Something like an overload of the Get-Item function that receives the URL would be ideal Thanks in advance
0 votes
1 answer
159 views

How to make query to form as part of base URL

I have a requirement where we need to retain a URL from a legacy system (Umbraco). The way legacy works is a search page that filters search results via query string but in the format of rest API. e....
1 vote
1 answer
307 views

Image hash in URL causes image to have black background in normal mode

I have a case where a PNG image appears differently in edit and preview mode versus normal mode. The normal mode image has black bars at the top and bottom of the image. The edit / preview image does ...
2 votes
1 answer
2k views

Redirecting to Lowercase URL and removing trailing slashes for SEO

I am working on a task where I need to make sure that all the requests are served through lowercase URL's in Sitecore 8.2. I have seen few articles around getting in done through IIS rewrite but than ...
2 votes
1 answer
1k views

Getting 404 error on a page when url is using item name

I keep on getting this annoying error when I'm trying to navigate to my site's page: {siteurl}/projects/name-of-project. But it is okay when: {siteurl}/projects/{item id}. Where in {item id} is the ...
0 votes
0 answers
226 views

Site config exclude relative path for few pages

I have my site definition like below: <site patch:before="site[@name='website']" name="mysite" hostName="mysite.com" scheme="https" notFoundItem="not-found" ...
1 vote
1 answer
2k views

Sitecore Url not working - layout not found error

We have just upgraded from Sitecore 8.1 update 4 to Sitecore 9.0 update 2. Almost all the functionalities are working. We have an issue with one url. When I tried to access the URL below, I got the ...
1 vote
1 answer
301 views

Can I include image URL options with Synthesis field rendering helpers?

I'm on Sitecore 8.2 with Synthesis 8.2.6. I'm currently using the provided helpers Field.RenderedValue and Field.Url. I'd like to request the images with specific size parameters depending on the ...
3 votes
2 answers
768 views

Unwanted Sitecore URL

I am able to access a page using the path: https://<<My Domain>>/Sitecore/content/page_path This has been crawled by Google, I don't want these URL's to be accessible. I would like to ...
4 votes
1 answer
871 views

MediaManager throwing null error

I am facing an issue while fetching the media item URL. This is my code snippet: @{ Sitecore.Data.Fields.ImageField imageItem = (Sitecore.Data.Fields.ImageField)Sitecore.Context.Item.Fields["...
3 votes
2 answers
26k views

How to reload the current page with a query string parameter

I'm trying to refresh a page when clicking tag href. But I could not get the current page URI in my MVC Razor view and How I get the current page URI and how I refresh the same page? e.g.: www....
2 votes
1 answer
427 views

Is it possible to teach the keepalive agent to overcome TLS/SSL certificate warnings?

We have an internal environment where the TLS/SSL certificate on tenants is not playing well with some requests. This is not a huge issue for clients who can add a one time trust for the certificate, ...
3 votes
2 answers
92 views

mutated vowel in display name and don't show it in the generated url

I have a multi language site and one language is german. I need language specific urls and so I am using the display name to generate the url and to show the Page titels and linknames to the internal ...
2 votes
0 answers
574 views

Language specific redirects with UrlRewrite sitecore module

I've done alot of looking around but I can't seem to find the answer to an issue I am facing. Is it possible to use the UrlRewrite module from the Sitecore marketplace to perform language specific ...
7 votes
1 answer
428 views

How do I allow only the configured language for each site?

I've a site in x languages and each language has its own domain and language like www.mycompany.de, www.mycompany.co.uk, www.mycompany.at, .... Currently, I can force another language - e.g. German ...
5 votes
1 answer
52 views

When should I use ScalableLinkProvider or ItemSearchLinkProvider?

I have noticed that the Sitecore.Buckets.LinkProviders namespace has 2 classes that extend the default LinkProvider: ScalableLinkProvider and ItemSearchLinkProvider. I cannot find any direct ...
2 votes
2 answers
1k views

How to avoid folder name in URL

I have site definition up to C. When accessing the properties in the URL Property page name is displayed. How to avoid it? Current Url:Http:/Sitename/en/Propert Page/PropertyName Expected URL:http:...
5 votes
2 answers
3k views

Why does MediaManager.GetMediaUrl() return internal "/sitecore/shell/-/media" URL instead of "~/media" URL?

I'm programatically inserting some JPGs into the Media Library with the MediaCreator and then putting URLs to those images in a Rich Text field another item (page). When I call MediaManager....
10 votes
1 answer
3k views

How to prevent Sitecore resolving the Language based on the URL

Our site is resolving some relative urls as languages, where it should be resolving items instead. e.g. mydomain.com/eu should be resolving the item EU under the home item. Instead, Sitecore is ...
7 votes
1 answer
160 views

Why does my marketing URL redirect me to the site root?

[Question transposed from Slack] We are trying to create a site with a virtualFolder of /chr. When we navigate to home page in the site, the system redirects us back to the site root. We have checked ...
2 votes
1 answer
512 views

Alias with query string

Using Sitecore aliases, I want to go the a page with a query string. For example I want to go to test/myOriginalPage?query=myQuery using an alias /myAlias. The only fields I could set are "Path" (...
1 vote
1 answer
118 views

Can we use "useDisplayName" for items outside of the Home folder?

I have a contribution folder with items on my sitecore website. I had to manually map the displayname to the items in my HttpRequestProcessor resolvers. However, I would like to confirm there is no ...
5 votes
1 answer
200 views

Does Sitecore support internationalization with Urls?

Clearly, Sitecore has great support for internationalization with built in language versions. However, one thing I have not been a fan of is that fact that all languages will have the same Url (at ...