Click here to Skip to main content
15,913,179 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Send value to server side Pin
Elham M4-Jun-11 9:39
Elham M4-Jun-11 9:39 
GeneralRe: Send value to server side Pin
Not Active4-Jun-11 10:08
mentorNot Active4-Jun-11 10:08 
GeneralRe: Send value to server side Pin
Elham M4-Jun-11 20:08
Elham M4-Jun-11 20:08 
GeneralRe: Send value to server side Pin
Not Active5-Jun-11 2:23
mentorNot Active5-Jun-11 2:23 
GeneralRe: Send value to server side Pin
Elham M5-Jun-11 7:47
Elham M5-Jun-11 7:47 
GeneralRe: Send value to server side Pin
Not Active5-Jun-11 8:25
mentorNot Active5-Jun-11 8:25 
GeneralRe: Send value to server side Pin
Elham M6-Jun-11 0:55
Elham M6-Jun-11 0:55 
GeneralRe: Send value to server side Pin
Not Active6-Jun-11 1:52
mentorNot Active6-Jun-11 1:52 
Elham M wrote:
client side is faster than server side

Not necessarily. There are many factors to consider.

By hard coding values into the JavaScript you have reduced the maintainability and extensibility of the code and application making it more difficult on yourself and those that may follow. Knowing the proper tools and when to use them is the mark of a real developer not just a hobbyist or hacker. Which are you?

You can easily get the values using JQuery

var menuVal = $("#menu").val();
var subMenuVal = $("#submenu").val();


One way of passing them to a server method

Code-behind

[WebMethod]
public static void Foo(string menu, string subMenu)
{
  ...
}

JavaScript
PageMethods.Foo( menuVal, subMenuVal);


I know the language. I've read a book. - _Madmatt

GeneralRe: Send value to server side Pin
Morgs Morgan8-Jun-11 1:17
Morgs Morgan8-Jun-11 1:17 
GeneralRe: Send value to server side Pin
Elham M8-Jun-11 7:54
Elham M8-Jun-11 7:54 
GeneralRe: Send value to server side Pin
Morgs Morgan8-Jun-11 21:20
Morgs Morgan8-Jun-11 21:20 
GeneralRe: Send value to server side Pin
Not Active8-Jun-11 8:37
mentorNot Active8-Jun-11 8:37 
GeneralRe: Send value to server side Pin
Morgs Morgan8-Jun-11 21:20
Morgs Morgan8-Jun-11 21:20 
GeneralRe: Send value to server side Pin
Elham M8-Jun-11 7:44
Elham M8-Jun-11 7:44 
AnswerRe: Send value to server side Pin
shankysharma863-Jun-11 2:08
shankysharma863-Jun-11 2:08 
GeneralRe: Send value to server side Pin
Not Active3-Jun-11 4:48
mentorNot Active3-Jun-11 4:48 
QuestionStoring and Retrieving Documents in SQL Server Pin
Aptiva Dave2-Jun-11 10:53
Aptiva Dave2-Jun-11 10:53 
AnswerRe: Storing and Retrieving Documents in SQL Server Pin
Blue_Boy2-Jun-11 20:36
Blue_Boy2-Jun-11 20:36 
AnswerRe: Storing and Retrieving Documents in SQL Server Pin
thatraja2-Jun-11 23:28
professionalthatraja2-Jun-11 23:28 
QuestionListBox Pin
jashimu2-Jun-11 4:21
jashimu2-Jun-11 4:21 
AnswerRe: ListBox Pin
shankysharma862-Jun-11 4:27
shankysharma862-Jun-11 4:27 
GeneralRe: ListBox Pin
jashimu2-Jun-11 4:42
jashimu2-Jun-11 4:42 
GeneralRe: ListBox Pin
shankysharma862-Jun-11 4:46
shankysharma862-Jun-11 4:46 
GeneralRe: ListBox Pin
gavindon2-Jun-11 5:45
gavindon2-Jun-11 5:45 
AnswerRe: ListBox Pin
Monjurul Habib2-Jun-11 9:48
professionalMonjurul Habib2-Jun-11 9:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.