Hi Ben
I use JS code to do this. That is it runs as part of the mediawiki
extension. The code for this can be see below, where I have tried to
use various approaches to detect the line space. What puzzle me is
that EVERBODY aught to have problems like this.... so I would supect
that there is a common solution????
Regards Per
p.s. I dont know where this happens :-), but I expect that it happens
on your PC, when you do it.

This is one snipp of code that works in FF, but not in IE....:

// function returns the next full stop position  in a string
function nextStop(text) {
         var pos = text.length;
         var pos2 = text.indexOf(".");
         if (pos2 > 0 && pos >pos2) { pos = pos2 +
1};
         var pos2 = text.indexOf("!");
         if (pos2 > 0 && pos >pos2) { pos = pos2 + 1};
         var pos2 = text.indexOf("?");
         if (pos2 > 0 && pos >pos2) { pos = pos2 + 1};

         var patt1 = /\x10/;
         var pos2 = text.search(patt1);
         if (pos2 > 0 && pos >pos2) { pos = pos2};

         var patt1 = /\x13/;
         var pos2 = text.search(patt1);
         if (pos2 > 0 && pos >pos2) { pos = pos2};

         var patt1 = /\n/;
         var pos2 = text.search(patt1);
         if (pos2 > 0 && pos >pos2) { pos = pos2};

         if (pos == 0) { pos = text.length };

   return pos;


}



On 10 Sep., 19:57, "Ben Lisbakken" <[EMAIL PROTECTED]> wrote:
> Asset --
>
> I see your problem, and I would agree that it seems like your splitting of
> text is not working correctly.  I'm sorry to say, though, that I don't know
> what the answer is.  Are you doing the translation on the server, or in
> Javascript?  If you're doing it on the server, you might as well split up
> the text there.
>
> -Ben
>
> On Wed, Sep 10, 2008 at 7:53 AM, Asset <[EMAIL PROTECTED]> wrote:
>
> > Now this link works  - so you should be abel to test/trace the
> > translation:
>
> >http://www.forskelsproduktion.dk/wiki/index.php?title=Play:Translate_...
>
> > On 8 Sep., 13:31, Asset <[EMAIL PROTECTED]> wrote:
> > > Sorry - the DNS is not working right now for unknown reasons. I will
> > > report back here when it works again!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google AJAX API" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/Google-AJAX-Search-API?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to