Developer forum

Forum » Templates » Nordic character passing through Dynamicweb.Input.Request("param") and IE

Nordic character passing through Dynamicweb.Input.Request("param") and IE

Dmitrij Jazel
Reply

Hi Guys,

Wanted to know if someone else encountered simmilar issue.

All I need to do is to ensure that string "p" is displayed correctly here.

In my razor template I have a link:

<a href="/Default.aspx?id=28&amp;param=Tilbehør">Tilbehør</a>

Than I read it like that:

string p = Dynamicweb.Input.Request("param");

 

As a result, IE is not displaying culture specific character (ø) correctly.

http://screencast.com/t/XHB2ci3PDs

 

I am also including charset meta in the master template

<!DOCTYPE html>
<!--[if IE 8]><html class="no-js lt-ie9" lang="no" ><![endif]-->
<!--[if gt IE 8]><!--><html class="no-js" lang="no" ><!--<![endif]-->
<head>
<meta charset="UTF-8">

 

Any suggestions how to fix this one?


Replies

 
Mikkel Ricky
Reply
This post has been marked as an answer

You have to url encode the query parameter value:

@System.Web.HttpUtility.UrlEncode("Tilbehør")

Best regards,
Mikkel

Votes for this answer: 1

 

You must be logged in to post in the forum