I'm a bit of a noob when it comes to PHP, and I'm having some trouble getting a bit of code to show properly on the page. The code is supposed to pull a CC image from flickr and display the image along with the required credit and description for the image pulled. I've tried several times to reach the original site designer without success. I've discovered quite a few sites designed by the same fellow that all have the same problem I'm seeing. Using IE7 (I don't know if it shows this way in other browsers) take a look at the photo in the middle of this page. feel free to view source as well to see what is happening. http://consolidationlibrary.com/Consolidation-photos.php notice the blue link line just to the left of the image and the blue link line surrounding the image. Those and the fact that it doesn't show the description and credit lines are what I want to get fixed. I'm hoping it's a simple super quick fix (add a " or remove a ") but if not I am willing to pay a reasonable amount for the time taken to make this work the way it is supposed to work. It shouldn't be too hard to point this error out to the other site owners and get "fix it" work from them too. So please take that into consideration. PM me if you think you can fix this and let me know what it will cost. Thanks, BOP
With all due respect... I believe the problem is in the PHP code that calls the image in from flickr. I've been through the styles (as the other respondent suggested) numerous times. No change to the styles has had any effect on the output. In an attempt to make it more clear, perhaps you can tell me why the following code tries to put TWO of the same image on the page.
The OUTPUT most certainly isn't PHP, so this is no PHP error. You are even TELLING people to view source, so what do you see when you do that? PHP? No.
Well, That was most helpful. I bow to your all knowing wisdom. May your grace and kindness serve you well all the days of your life. The above may or may not contain sarcasm
This last part... if (isset($rss_channel["ITEMS"])) { if (count($rss_channel["ITEMS"]) > 0) { if (count($rss_channel["ITEMS"]) > $flickrlimit) {$NumberOfItems = $flickrlimit;} else {$NumberOfItems = count($rss_channel["ITEMS"]);} for($i = 0;$i < $NumberOfItems;$i++) { if (isset($rss_channel["ITEMS"][$i]["LINK"])) { print ("\n<div class=\"noshow\"><a target=\"_blank\" href=\"" . $rss_channel["ITEMS"][$i]["LINK"] . "\">" . $rss_channel["ITEMS"][$i]["TITLE"] . "</a></div>"); } else { print ("\n<div class=\"noshow\">" . none . "</div>"); } print ("<div class=\"instant\" id=\"none\">" . preg_replace($patterns,$replacements,$rss_channel["ITEMS"][$i]["DESCRIPTION"]) . "</div>"); } } else { print ("No News Found"); } } ?> PHP: Im not making any guarantees, but try replacing with this: if (isset($rss_channel["ITEMS"])) { if (count($rss_channel["ITEMS"]) > 0) { if (count($rss_channel["ITEMS"]) > $flickrlimit) {$NumberOfItems = $flickrlimit;} else {$NumberOfItems = count($rss_channel["ITEMS"]);} for($i = 0;$i < $NumberOfItems;$i++) { if (isset($rss_channel["ITEMS"][$i]["LINK"])) { print ("\n<div><a target=\"_blank\" href=\"" . $rss_channel["ITEMS"][$i]["LINK"] . "\">" . $rss_channel["ITEMS"][$i]["TITLE"] . "</a></div>"); } else { print ("\n<div>" . none . "</div>"); } print ("<div>" . preg_replace($patterns,$replacements,$rss_channel["ITEMS"][$i]["DESCRIPTION"]) . "</div>"); } } else { print ("No News Found"); } } ?> PHP:
Thank you very much! That is a great improvement! Now If I can just get the style part right I think this is licked. +rep to you (tis the least I can do!)