Get and Post Method using Masterpage [Resolved]

Posted by Bugwee under Regular Expressions on 5/5/2011 | Points: 10 | Views : 5823 | Status : [Member] | Replies : 5
Hello,

Could I apply or use a post or get method when using a masterpage? how could i achieve or get the values being passed from the source page to destination page?

any idea will be appreciated.

Thanks




Responses

Posted by: Bugwee on: 5/5/2011 [Member] Starter | Points: 25

Up
0
Down

Resolved
hi,

i have able to fixed my own problem, but still i want any other solution aside from this.. using the post method on my masterpage.

source page:
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">

<asp:TextBox ID="txtBugwee" runat="server" Text="test"></asp:TextBox>
</asp:Content>


destination page:
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">

<asp:TextBox ID="txtBugweed" runat="server"></asp:TextBox>
</asp:Content>


i have a content placeholder since i am using a masterpage.
on the destination page load event i write this one and that would fix the problem
txtBugweed.Text = Page.Request.Form("ctl00$ContentPlaceHolder1$txtBugwee")


but i am doubtful why i couldn't retrieve the data using below
txtBugweed.Text = Page.Request.Form("txtBugwee")








Bugwee, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Nishithraj on: 5/6/2011 [Member] Bronze | Points: 25

Up
0
Down
The reason is very clear. You have tried with actual id txtBugwee of the control which won't be there in the page. You should use the clientid for this purpose.

Mark this as answer, if it is.....

With regards
Nishithraj Narayanan

Bugwee, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Bugwee on: 5/6/2011 [Member] Starter | Points: 25

Up
0
Down
hi Nishithraj,

i got your point and now i understand its means. i'm not confuse anymore with this

Thanks


Bugwee, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Nishithraj on: 5/6/2011 [Member] Bronze | Points: 25

Up
0
Down
Okey, That's great..

Mark this as answer, if it is.....

With regards
Nishithraj Narayanan

Bugwee, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Veera8383 on: 12/26/2016 [Member] Starter | Points: 25

Up
0
Down
Hi Bugwee..,

I have two website(like payment gateway ) . I post data from one site to another , the source have nested or single master page how i can access data from second website.

Thanks,
Veeramani

Bugwee, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response