-
Simple htmlText question
I can really use your help.
Simple question, is the following valid htmlText, or do I need a <P> tag?
<FONT COLOR=#B5BD8E>cool bands</FONT><BR><FONT COLOR=#FFFFFF><U><A HREF=http://www.agathacrawl.com>agathacrawl.com</A></U></FONT><BR><BR><BR><BR><BR><BR><BR><BR><BR><BR><BR>< BR>
-
Senior Member
I've found that in html text fields, the color tag only works if you put single or double quotes around the color value, e.g:
<FONT COLOR="#B5BD8E">
I've also had problems using <p>. It behaves pretty much the same as <br> if you surround each paragraph with an opening and closing <p> tag. Like so:
<p>the text</p>
But it's easier to just use <br>
Also, if you're finding that <br> and <p> are STILL not working, make sure your text field is set to multiline.
- Jim
-
Thanks Jbum!
That got the first part of the data displaying. The rest still is not. Here is the code that is creating the htmlText:
Code:
function makeText(a){
if(a == 4){
for(i=1; i<=13; i++){ //13 is the number of lines available for display
trace("linksAkey"+i+": "+_root["linksAkey_"+i]);
trace("linksAname"+i+": "+_root["linksAname_"+i]);
if(_root["linksAkey_"+i] == 0){
_root.Astring += '<BR>';
}else if(_root["linksAkey_"+i] == 1){
_root.Astring += '<FONT COLOR="#B5BD8E">';
_root.Astring += _root["linksAname_"+i];
_root.Astring += '</FONT><BR>';
}else if(_root["linksAkey_"+i] == 2){
_root.Astring += '<FONT COLOR="#FFFFFF"><U><A HREF="http://"';
_root.Astring += _root["linksAurl_"+i];
_root.Astring += '">';
_root.Astring += _root["linksAname_"+i];
_root.Astring += '</A></U></FONT><BR>';
}
trace(_root.Astring);
}
}
}
-
Senior Member
Did you make sure the field is set to multiline?
If so, I would try temporarily commenting out parts of your script and using something simple like
_root.Astring += 'B';
Just to make sure the code is exectuting and appending stuff properly.
Then gradually add the HTML stuff back in to find the offending line. E.g:
_root.Astring += 'B<BR>';
.
.
.
_root.Astring += '<A href="url">B</a><BR>';
.
.
.
etc. etc.
- Jim
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|