Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

ASP.NET Forum


You are currently viewing our ASP.NET Forum as a guest. Please register to participate.
Login



Reply
Input text box cutting off asp variable
Old 02-18-2007, 04:02 PM Input text box cutting off asp variable
Super Talker

Posts: 116
Trades: 0
Hi everyone,

I'm having a huge problem with writing either a variable into a text box or a value from a database.

I have an email form with a From Name: <input text> field.

Ex: <input type="text" name="FromName" size="40" />

I'm trying to put my name into this input field either from a database or as a variable.

Ex: dim lcResearcherName

lcResearcherName="Donna Zukowsk"

When I try to point the value to lcResearcherName, only my first name comes up in the field. Not the last.

I tried:
<input type="text" name="FromName" size="40" value=<% Response.Write(lcResearcherName) %>/>

Still only my first name.

Then I tried:
<input type="text" name="FromName" size="40" value=<% =(lcResearcherName) %>/>

Still only my first name. I then tried breaking my name into two variables as in lcFirstName="Donna" and lcLastName="Zukowski")

I then did:
<input type="text" name="FromName" size="40" value=<% Response.Write(lcFirstName & " " & lcLastName) %>/>

Only my first name comes up. If I try to do with reading from a database the problem still happens.

I hear this is a problem too with PHP. Any suggestions?

Donna
DonnaZ is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 02-18-2007, 04:37 PM Re: Input text box cutting off asp variable
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,517
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
you have no delimiters (") for the text box value, so as HTML also uses a space as a delimiter for form element attributes, the value is broken at the first space it finds.


BTW this is the ASP forum but the same thing would occur with any server side code.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is offline
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 02-21-2007, 10:02 AM Re: Input text box cutting off asp variable
Super Talker

Posts: 116
Trades: 0
Thanks. You can't tell I'm overworked eh? DZ
DonnaZ is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Input text box cutting off asp variable
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.11697 seconds with 12 queries