Thank you both for your responses, they are ways in which I would never have thought to construct a select statement and work well. I'm using Rudy's way as it displays only the users who have groupA and groupB in their profile. Do you guys think in terms of set theory when you create statements...
This is probably very simple, like most of my questions but I can't narrow my search on the web.
I've two tables
Users and UserGroups; Users store information about users, Usergroups store groups subscribed to by each user; primary/referential key between them is userID; this is a one to many...
Thanks for the pointers, I've taken your advice and am now trying to avoid saving in the application folders. Having got a working page, I've just discovered my problem now is that JSP doesn't support multipart/form-data enctypes! So I can upload an image but I cannot pass regular form data...
I'm trying to convert a piece of code that I got working on Windows, but I am unable to convert for Linux. I'm trying to upload an image using <input type="file" name="filename" size="50">
The following is the submitting page(upload.jsp) which attempts to upload the file located from the...
That doesn't seem to work, I've removed the UserID column from the excel file and imported that file with one column short.
This only results in the next column being entered one column earier, this doesn't work as the next column is the name field.
I'm importing using Navicat but that...
I'm guessing this is a fairly common request and it's so obvious that I can't find an answer on the web after half hour of searching.
My problem is this: I've already a table constructed with usernames and details, and the UserID field for this table autoincrements. I now have a list of users...
<script>document.forms[0].country.value='<%=countryDB%>'</script>
That's the baby! I was amending an existing page and didn't fancy creating a new table or array for 100 countries. Terrible I know, but much easier to copy and paste.
I appreciate this wasn't a JSP question in the end, but I...
The problem is like this:
I have a string value retrieved from the database detailing the country this person last entered as their home country.
I have a drop down box (which they originally chose from and whose value was submitted into the database I now wish to retrieve from).
I want to...
Oops, should have been
<%if (countryDB.equals("Afghanistan")) {%> selected <%} %>
as opposed to
<%if (country.equals("Afghanistan")) {%> selected <%} %>
I'm trying to save and retrieve status for a submitted form on a JSP. Retrieving textbox answers is relatively simple but for selection boxes I'm doing this:
<%String countryDB = rs.getString("countryDB"); %> //get value last submitted
<td valign="TOP" height="21" colspan="3">...
I'm trying to save and retrieve status for a submitted form on a JSP. Retrieving textbox answers is relatively simple but for selection boxes I'm doing this:
<%String countryDB = rs.getString("countryDB"); %> //get value last submitted
<td valign="TOP" height="21" colspan="3">...
I plan to default the values chosen already via server-side, but this won't help if the user makes changes to these values, moves onto the next page but then clicks 'back' on the browser. If I/anyone can solve the problem of just the code above, and can make the page keep track of the <select>...
I've found this lovely menu swapper from JavaScript Source which does almost exactly what I want. Only problem is that it doesn't keep track of which select variables were selected if you need to go back to that page once you've pressed submit. I've included checkboxes in the code below which do...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.