Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
www.mysite.com/blog?id=123 can read the parameter(id) value in macro partial view.
www.mysite.com/blog/#id=123 can't read the parameter(id) value in macro partial view and it display empty macros.
In macro,
if (System.Web.HttpContext.Current.Request["id"] != null) { c = System.Web.HttpContext.Current.Request["id"]; }
In Template, placing the macro
<umbraco:macro ID="Macro3" Alias="blogListing" runat="server"></umbraco:Macro>
parameters in hash tag (#) is not read by server, it's client side operation.
Hi Adam,
Yakov is right. A querystring should start with a ? otherwise it's not recognized as query paramenter serverside.
The # is pointer to a anchor on your page. This is never sent to the server.
Dave
Thank u guys for your response
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
read parameters after # in url
www.mysite.com/blog?id=123 can read the parameter(id) value in macro partial view.
www.mysite.com/blog/#id=123 can't read the parameter(id) value in macro partial view and it display empty macros.
In macro,
if (System.Web.HttpContext.Current.Request["id"] != null) { c = System.Web.HttpContext.Current.Request["id"]; }
In Template, placing the macro
parameters in hash tag (#) is not read by server, it's client side operation.
Hi Adam,
Yakov is right. A querystring should start with a ? otherwise it's not recognized as query paramenter serverside.
The # is pointer to a anchor on your page. This is never sent to the server.
Dave
Thank u guys for your response
is working on a reply...