[Solved] Whats wrong with this $return?


You’ve got <?php ?> inside existing PHP code. You cannot nest <?php ?>. Since you are using double quotes, simple variables like $kinsource will be interpolated but the function call to get_bloginfo() will have to be concatenated in. Switch all other double quotes inside the string to single quotes.

$return .= "<a href="https://stackoverflow.com/questions/9354628/$kinsource" class="lightbox" rel="pics"><img src="" . get_bloginfo("template_url') ."/timthumb.php?src="{$kinsource}&w=120&h=120&zc=1" alt=""/></a>";

Note, I’ve also surrounded $kinsource in {} when it runs into other strings for readability, though it won’t negatively affect the parsing in this situation if that isn’t done.

2

solved Whats wrong with this $return?