you can define <init-param> inside a servlet, which can be accessed from the same servlet like:
<servlet>
<servlet-name>abc</servlet-name>
<servlet-class>abc</servlet-class>
<init-param>
<param-name>n1</param-name>
<param-value>100</param-value>
</init-param>
</servlet>
Access : int x = getInitParameter("n1");
it can be accessed within the same servlet.
In your case you should use <context-param>
<context-param>
<param-name>n1</param-name>
<param-value>100</param-value>
</context-param>
Access : int i = getServletContext.getInitParameter("n1");
I already knows java programming language at a professional level like i had developed some web-apps for my startup.
But right now my project needs perl.
so, i want to learn perl now.
can you guys please suggest me the best book to learn perl. so, that i am able to solve critical work issues using perl script and i would be able to use my brain in develoiping the perl scripts.
please i need to be productive in perl As Soon As Possible.
I want c:set to display the id of a selected row (name for the above code), but it only gets the last row's (loaded) id. How to do that, please help..
jsp jstl
my problem : please check the red coloured lines in code above, here i want to send different value of res_pkey to my-offers according to the user selected row of the table, thats why i am using it in the anchor tag.
previously i tried : <c:set> but it updates its value during loading of the page and set it to the last row's value.
I want : when user select a row, only that perticular value should be given to tha my-offers
please help me, stucked in this, from half of the day.. please :)
actually i am using bootstrap..
yes Bear Bibeault, you caught my feelings.. :)
and thanks Bear Bibeault, i think,i got my answer,,
what i done till now :
i create one header file , and import all the jqueries, javascripts in that page, and use <jsp:include> on each page because every page needs header, and with that header all the javascripts, jquery are also included in each page
is it the best practice of placing all the scripts use in different pages to be placed in the header file??
I think no because if a page do not uses a particular script and it is still loading and wasting processing time and memory..
what is the correct way..
please correct me..