RE: [PHP-WIN] News with MySQL

From: Date: Thu, 15 Mar 2001 13:30:46 +0000
Subject: RE: [PHP-WIN] News with MySQL
Groups: php.windows 
Request: Send a blank email to php-windows+get-6060@lists.php.net to get a copy of this message
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 - jasendorf@lcounty.com 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:NunzioM@Datavia.co.za] > Sent: Thursday, March 15, 2001 1:46 AM > To: php-windows@lists.php.net > 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: php-windows-unsubscribe@lists.php.net > For additional commands, e-mail: php-windows-help@lists.php.net > To contact the list administrators, e-mail: > php-list-admin@lists.php.net >

« previous php.windows (#6060) next »