By: PhilE
Date: 2005-05-22
Time: 15:18
|
unwanted <br /> being insertedg'day all,
I have a simple 3 column table displaying name, phone and url. If the url field, (3rd column) is empty, a <br /> tag is inserted after the first <td> tag of that row. If there is data in the url field, no <br /> tag is inserted. This means that rows end up different heights. There are no <br /> in either the htm or php files. Why is this tag being inserted, and how do I prevent it, if possible. PhilE |
|||
By: Pirjo Posio
Date: 2005-05-22
Time: 20:51
|
Re: unwanted <br /> being insertedHi PhilE,
You gave no code here, so I make a partial model here:
In the above code for the third <td> field there is a parameter dot. This parameter will give a non-breaking space if the data for field3 is empty. The dot is so invisible that many people don't see it easily. |
|||
By: PhilE
Date: 2005-05-23
Time: 00:37
|
Re: unwanted <br /> being insertedThanks for your suggestion, but I have tried that. It seems that if no url is found in the url field in the mysql table the <br /> is added. I have tried putting just a zero in the url field in the mysql table and I still get a <br /> added in.
The code is just a mod of one of the examples. This is the php code
This is the html code
and this is the resulting source code
Note the <br /> tag in the row without the url. I have tried it without any styles, with and without the parameter dot. I have tried setting a line height, adding in my own <br /> tag. I'm just trying TBS out, so am still exploring all the in and outs. I'm sure its a simple error on my part, I just can't see where. |
|||
By: PhilE
Date: 2005-05-23
Time: 01:25
|
Re: unwanted <br /> being insertedby the way, the only place I can find a <br /> in tbs_class.php is in the error message section, line 2143 or thereabouts. I tried removing them but that made no difference either.
PhilE |
|||
By: Skrol29
Date: 2005-05-23
Time: 02:33
|
Re: unwanted <br /> being insertedHi,
It seems that the break line comes from the value of the field. You can check that by adding parameter 'htmlconv=nobr" in the blk1.name tag. If the br comes from the value of the fields, then it will be no longer displayed using this parameter. |
|||
By: PhilE
Date: 2005-05-23
Time: 03:34
|
Re: unwanted <br /> being insertedthanks Skrol, that's fixed it. I'm not sure I understand why, but it works like I wanted it to now.
PhilE |
|||
By: Skrol29
Date: 2005-05-23
Time: 11:49
|
Re: unwanted <br /> being insertedYour data has a new line character at the beginning.
|
|||
By: PhilE
Date: 2005-05-23
Time: 12:22
|
Re: unwanted <br /> being insertedok, I don't know how they got there, but that could explain some other funny behaviour, such as an alphabetical sort giving me two groups, with those records containing an url sorted separately at the end of the list. An update of the record must remove the offending character. I will now see if I can figure out how to get rid of them without doing an edit save on every record.
Thank you so much for your assistance with my problem. PhilE |