unwanted appearance of image
Hello,
Here are the problematic three lines of code:
<?php $shortbio = substr((($rsAllPresenterData->getColumnVal("Biography",false))), 0, 1000) ; ?>
<?php $shortbio = preg_replace("/<img[^>]+\>/i", "", $shortbio) ; ?>
<?php echo ($shortbio) ; ?>
Obviously, the first uses substr () to extract the first 1,000 characters of the CK editor representation that is a full length Presenter Biography.
Second line removes all images so I can display only that summary text.
ISSUE: When extracted character length is 1500 or 2000 characters, I get text with no images as requested.
HOWEVER, when extracted length = 1000 characters, an extra (unwanted) image sneaks in. And I don't know how to stop it.
I need the short bio version with no images for a "Here are all your Presenters" on a Listing Page; with a link people can click to go to each individual Presenters details page.
This will not work when random images creep in, and as when substr is set for 1,000 characters.
I will give you necessary URLs and username plus password credentials so you can see the effect I describe in the upcoming private area
Thank you.