andy
Posts: 183
|
| Posted: 05/29/2008, 4:18 PM |
|
Hi
I am using the autofill feature, which works fine unless one of the fields being returned contains a newline / hard return in it.
Where this is the case it doesn't work.
Is there a way of retrieving memo fields?
Thanks.
_________________
Andy
RAD tools for rich UI controls:
http://www.koolphptools.com |
 |
 |
wkempees
Posts: 1679
|
| Posted: 05/31/2008, 5:08 AM |
|
Bump
_________________
Origin: NL, T:GMT+1 (Forumtime +9)
CCS3/4.01.006 PhP, MySQL .Net/InMotion(Vista/XP, XAMPP)
if you liked this info PAYPAL me: http://donate.consultair.eu
|
 |
 |
andy
Posts: 183
|
| Posted: 06/01/2008, 11:58 AM |
|
Just an idea, which I haven't thought through yet, but one possible way around this is to convert the memo field to html ideally when entered using FCKEditor whereby all hardreturns are converted to <br> codes. Alternatively have a routine to convert any line breaks to <br> codes before it is imported.
Any ideas on how to do this would be great...
P.S. Was bedoelt je met "bump"? Hit a brick wall?
_________________
Andy
RAD tools for rich UI controls:
http://www.koolphptools.com |
 |
 |
wkempees
Posts: 1679
|
| Posted: 06/01/2008, 3:45 PM |
|
Dutch:
"Bump" is de manier om een post hernieuwd onder de aandacht te brengen.
Vond ik nodig gezien het belang van jouw vraag.
[ PM ] me.
/Dutch
Bump is the way, brick walls are there to be bumped.
I thought your post was interesting enough to be bumped to top of post list.
BTW: PHP function hard return to html <br>
$str = nl2br($str);
source: http://nl.php.net/nl2br
Walter
_________________
Origin: NL, T:GMT+1 (Forumtime +9)
CCS3/4.01.006 PhP, MySQL .Net/InMotion(Vista/XP, XAMPP)
if you liked this info PAYPAL me: http://donate.consultair.eu
|
 |
 |
andy
Posts: 183
|
| Posted: 06/01/2008, 4:02 PM |
|
Bedankt Walter
Unfortunately nl2br adds the <br /> but also formats a carriage return after the <br />, which means the autofill still doesn't work.
This one does work, however (not with FCKeditor just with a plain text area):
In BeforeUpdate and BeforeAdd event of grid:
global $mygrid;
$str = $mygrid->mytextarea->GetValue();
$order = array("\r\n", "\n", "\r");
$replace = '<br />';
$mygrid->mytextarea->SetValue(str_replace($order, $replace, $str));
_________________
Andy
RAD tools for rich UI controls:
http://www.koolphptools.com |
 |
 |
|