dio Posted May 13, 2004 Report Share Posted May 13, 2004 būšu neizsakāmi pateicīgs cilvēkam, kurš iedos skriptu, kas aplauž pārlieku garus vārdus komentāros Link to comment Share on other sites More sharing options...
bubu Posted May 13, 2004 Report Share Posted May 13, 2004 $teksts = substr($teksts, 0, 20); // nogriezh pirmos 20 simbolus Link to comment Share on other sites More sharing options...
hu_ha Posted May 13, 2004 Report Share Posted May 13, 2004 nu es nezinu vai tieshaam tu gribi tos vaardus aplauzt.. driizaak jau tevi tie garie vaardi izjauc tavas lapas dizainu. tad var lietot taadu funkciju kaa wordwrap Link to comment Share on other sites More sharing options...
Aleksejs Posted May 13, 2004 Report Share Posted May 13, 2004 (edited) Ar "aplaušanu" gadījumā nav domāta vārda sadalīšana pa zilbēm? Gribētos tādu brīnumu redzēt... Tjipa, kas saliek starp zilbēm. Edited May 13, 2004 by Aleksejs Link to comment Share on other sites More sharing options...
sviesc Posted May 14, 2004 Report Share Posted May 14, 2004 (edited) tas tak ir elementāri ņem te Tev visa pakete $comments1 = strip_tags($comments); //apgiežam visus HTML tagus $comments1 = nl2br($comments1); // entar par <br /> $comments1 = substr($comments1, 0, 2500); // maksimālais texta - simbolu skaits $comments1 = ereg_replace("([^ ]{55})","\\1<br>",$comments1); // ik pēc 55 simboliem liekam <br> (tipa ja vārds pārsniedz 55 simbolus) :blink: Edited May 14, 2004 by sviesc Link to comment Share on other sites More sharing options...
dio Posted May 14, 2004 Author Report Share Posted May 14, 2004 paldies, sviesc saprata :)) gribēju latviskāk, sanāca parasti. Link to comment Share on other sites More sharing options...
Recommended Posts