By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,635 Members | 2,187 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,635 IT Pros & Developers. It's quick & easy.

Does input field can store a thousand characters?

P: n/a
Hi,

I need to create a hidden field (the same as input field), but this
field needs to store at least a thousand characters? It is possible
when submitting those data to the server? Any help is really
appreciated.

Thanks
Chamnap
Jan 7 '08 #1
Share this Question
Share on Google+
12 Replies


P: n/a
Chamnap wrote:
Hi,

I need to create a hidden field (the same as input field), but this
field needs to store at least a thousand characters?
>It is possible when submitting those data to the server?
Yes, using POST method of the FORM element.Mick
Jan 7 '08 #2

P: n/a
Chamnap wrote:
I need to create a hidden field (the same as input field), but this
field needs to store at least a thousand characters?
You should have no problem if you use METHOD=POST. If you use METHOD=GET
then you may run into a limitation on the maximum length of the input
string. You'd also generate some very funny looking URL's is you used GET.

--
Steve Swift
http://www.swiftys.org.uk/swifty.html
http://www.ringers.org.uk
Jan 7 '08 #3

P: n/a
Chamnap said:
Hi,

I need to create a hidden field (the same as input field), but this
field needs to store at least a thousand characters?
Your question has already been answered, of course, just as an aside, if
you're interested in preserving the newlines and such in the text, you
will want to make sure you're using either a textarea or an input with
multiline="true" set as an attribute.

/* End completely unnecessary post */

~A!

--
anthony at my pet programmer dot com
Jan 7 '08 #4

P: n/a
Anthony Levensalor wrote:
Chamnap said:
>I need to create a hidden field (the same as input field), but this
field needs to store at least a thousand characters?

Your question has already been answered, of course, just as an aside, if
you're interested in preserving the newlines and such in the text, you
will want to make sure you're using either a textarea or an input with
multiline="true" set as an attribute.
However, that attribute is, of course, not Valid at all.
PointedEars
--
var bugRiddenCrashPronePieceOfJunk = (
navigator.userAgent.indexOf('MSIE 5') != -1
&& navigator.userAgent.indexOf('Mac') != -1
) // Plone, register_function.js:16
Jan 8 '08 #5

P: n/a
One more question, guys! I need to handle ajax json response. Beside
using eval ( "(" + request.responseText + ")" ), are there any ways
beside that? eval should be used here or not?

Thanks
Chamnap
Jan 8 '08 #6

P: n/a
Thomas 'PointedEars' Lahn said:
However, that attribute is, of course, not Valid at all.
Of course, according to
http://www.w3.org/TR/html4/interact/forms.html#h-17.4

You're 100% correct. I hereby amend my response to read:
"if you're interested in preserving the newlines and such in the text,
you will want to make sure you're using a textarea."

And if you could sound just a teensy bit more snotty, I'd find the
energy to call you out on it. You're like that teacher that needs his
students to feel like morons so that he can feel good about himself.

Honestly, life is not that bad.

Here's another way to say it, just for the edification of people who do
not want to be, well, ire-inducing:

"Don't use the multiline attribute, as it is not valid markup according to:
http://www.w3.org/TR/html4/interact/forms.html#h-17.4"

Or another:

"That last comment about multiline is actually invalid markup, check out
http://www.w3.org/TR/html4/interact/forms.html#h-17.4"

OR:

"Oops, I wouldn't count on multiline to work, it's not valid markup. The
official specification for the input tag is located at:
http://www.w3.org/TR/html4/interact/forms.html#h-17.4"

And I suppose there are about 32,768 other ways to say it that wouldn't
infer that the person you're correcting should have known better by some
kind of osmosis.

Please do notice as well that rather than just making a flippant
comment, references are fun and very educational.

And blah, who cares? It's usenet, right? We get to be whatever kind of
lofty, crusty old jerks we wanna be, because no one can call us on our
natures. Hell, we're above normal human interaction, we code for a living!

Oh, and thanks for the correction. Much obliged.

~A!

--
anthony at my pet programmer dot com
Jan 8 '08 #7

P: n/a
Chamnap said:
One more question, guys! I need to handle ajax json response. Beside
using eval ( "(" + request.responseText + ")" ), are there any ways
beside that? eval should be used here or not?
We just spent some time discussing that, actually. Here's a link to that
discussion:
http://groups.google.com/group/comp....dd48f8456744b4

Sorry for the long url, I am far too lazy to tinyurl it this evening.

~A!
--
anthony at my pet programmer dot com
Jan 8 '08 #8

P: n/a
Sorry for the long url, I am far too lazy to tinyurl it this evening.

Never mind, thanks!

Chamnap
Jan 8 '08 #9

P: n/a
Anthony Levensalor said the following on 1/7/2008 8:34 PM:
Chamnap said:
>One more question, guys! I need to handle ajax json response. Beside
using eval ( "(" + request.responseText + ")" ), are there any ways
beside that? eval should be used here or not?

We just spent some time discussing that, actually. Here's a link to that
discussion:
http://groups.google.com/group/comp....dd48f8456744b4
Sorry for the long url, I am far too lazy to tinyurl it this evening.
When given the choice between an actual URL and a tinyurl, in
comp.lang.javascript, post the actual URL. It lets people know exactly
where they are going instead of wherever tinyurl decides to redirect
them to.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Jan 8 '08 #10

P: n/a
On Tue, 08 Jan 2008 00:17:43 -0500, Randy Webb wrote:
When given the choice between an actual URL and a tinyurl, in
comp.lang.javascript, post the actual URL. It lets people know exactly
where they are going instead of wherever tinyurl decides to redirect
them to.
There are some well-explained reasons to avoid tinyurl's here:

<URL: http://gojomo.blogspot.com/2006/02/t...evil-urls.html >

Not to mention that indirect links through tinyurl and other type services
do not count as links in search engine ranking. When someone thinks
enough of my stuff to link to it, but takes an extra step to not let
Google know, it kind of irks me. *grin*
Jan 8 '08 #11

P: n/a
Jeremy J Starcher said the following on 1/8/2008 12:29 AM:
On Tue, 08 Jan 2008 00:17:43 -0500, Randy Webb wrote:
>When given the choice between an actual URL and a tinyurl, in
comp.lang.javascript, post the actual URL. It lets people know exactly
where they are going instead of wherever tinyurl decides to redirect
them to.

There are some well-explained reasons to avoid tinyurl's here:

<URL: http://gojomo.blogspot.com/2006/02/t...evil-urls.html >
I had never seen that before, not even one like it. I have it saved now
for the future URL services. Thank you :)

I hate issue #1 the most. I want to know where a link is going to take me.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Jan 8 '08 #12

P: n/a
Randy Webb said:
Jeremy J Starcher said the following on 1/8/2008 12:29 AM:
>There are some well-explained reasons to avoid tinyurl's here:

<URL: http://gojomo.blogspot.com/2006/02/t...evil-urls.html >

I had never seen that before, not even one like it. I have it saved now
for the future URL services. Thank you :)

I hate issue #1 the most. I want to know where a link is going to take me.
Thanks, guys! I appreciate the feedback!

~A!
--
anthony at my pet programmer dot com
Jan 8 '08 #13

This discussion thread is closed

Replies have been disabled for this discussion.