hi guys, just want to ask if how can i display the value of the textbox in javascript? as in, i will output it
xuexue 15 Junior Poster
Recommended Answers
Jump to Postare you wanting to access the text server side or client side?
A simple clientside access is using javascript. First, the textbox must have a unique id. Then the easiest way to access it is like this:
var boxtext = document.getElementById('uniqueid').value;
Jump to PostI can't see why you don't use a form button. That's what they're for. If you were using an ajax function to get certain info, like synchronising two dropdowns, fair enough, but it seems that you're actually navigating to a new page. For that you may as well use a …
Jump to PostThe best way to do this is with AJAX. The basic principle is that you pass data to the server which executes it while continue running the current page, without the need to reload.
This is the code
function createPostAjax(openThis,parameters) { var AJAX = null; if …
Jump to PostIF you need to use Ajax, perhaps a js 'framework'/thingy like jQuery or Prototype would be useful. It takes care of the response object and simplifies post operations. I hate the idea of having to declare an IE ActiveX as well as the more straightforward XMLHttpRequest.
All 14 Replies
ambius 0 Newbie Poster
xuexue 15 Junior Poster
ambius 0 Newbie Poster
xuexue 15 Junior Poster
ambius 0 Newbie Poster
xuexue 15 Junior Poster
ambius 0 Newbie Poster
xuexue 15 Junior Poster
muralibobby2015 17 Posting Pro

diafol
ambius 0 Newbie Poster
K0ns3rv 0 Junior Poster in Training

diafol
xuexue 15 Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.