Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
私の PHP スクリプトは Freebase API を呼び出し、パラグラフを出力します。次に、少しの正規表現とその他の解析マジックを実行し、変数にデータを返します$paragraph。段落は複数の文で構成されています。私がやりたいのは、代わりに短いバージョンの段落を返すことです。
$paragraph
最初の文を表示したい。100文字未満の場合は、少なくとも100文字になるまで次の文を表示したいと思います。
これどうやってするの?