I'm doing the same thing kind of differently. Instead of storing the first
paragraph seperately from the whole story I'm just reading up to the first
<br> (which I insert when the story is typed in by the user)
The code for just using the first paragraph looks like this:
else {
$story = split ("<br>", $story, 2);
echo "<P>$place - ${story[0]} <a
href=\"${full_story_page}?print=true&story_key=$key\">Read
more...</a></P>\n\n";
}
$story is the whole story pulled
The split breaks the story up in to bieces by <br>'s and then the
${story[0]} just uses the first piece...
Good Luck!
---------------------
John Asendorf - [EMAIL PROTECTED]
Web Applications Developer
http://www.lcounty.com - NEW FEATURES ADDED DAILY!
Licking County, Ohio, USA
740-349-3631
Aut insanit homo, aut versus facit
> -----Original Message-----
> From: Mangiola Nunzio Datavia [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, March 15, 2001 1:46 AM
> To: [EMAIL PROTECTED]
> Subject: [PHP-WIN] News with MySQL
>
>
> Hi
>
> What I would like to do is save a news
> item as a html or text file. Then place it into
> a MySQL database. Afterwards I would like
> to display the fist paragraph of each news
> posting on a site in a summary format.
>
> If the user would like to see more all
> he has to do is click on the corresponding
> link and it will take him to the full story.
>
> Now I know how to upload files and download
> full files from the database. I also
> know how to strip the first paragraph of an
> HTML file. But how to put them
> together?
>
> Anybody got any pointers?
>
> --
> PHP Windows Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail:
> [EMAIL PROTECTED]
>
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]