I just upgraded my gallery from 1.1 to 1.3, but I have some trouble with the displayimage.php.
When I try to look at a picture I get an empty page with this error:
QuoteTemplate error
Failed to find block 'ipinfo'(#(<!-- BEGIN ipinfo -->)(.*?)(<!-- END ipinfo -->)#s) in :
<tr>
<td>
<table width="100%" cellpadding="0" cellspacing="0">
<td class="tableh2_compact" nowrap>
<b>{MSG_AUTHOR}</b>
</td>
<td class="tableh2_compact" align="right" width="100%">
{BUTTONS}
</td>
<td class="tableh2_compact" align="right" nowrap>
<span class="comment_date">[{MSG_DATE}]</span>
</td>
</table>
</td>
</tr>
<tr>
<td class="tableb_compact">
<div id="cbody{MSG_ID}" style="display:block">
{MSG_BODY}
</div>
<div id="cedit{MSG_ID}" style="display:none">
{EDIT}
</div>
</td>
</tr>
Because I only need the 'add to favorites' link I used my old displayimage.php and pasted the next code in there:
// Create the add to fav link
if (!in_array($CURRENT_PIC_DATA['pid'], $FAVPICS)) {
$info[$lang_picinfo['addFavPhrase']] = "<a href=addfav.php?pid=" . $CURRENT_PIC_DATA['pid'] . " >" . $lang_picinfo['addFav'] . '</a>';
} else {
$info[$lang_picinfo['addFavPhrase']] = "<a href=addfav.php?pid=" . $CURRENT_PIC_DATA['pid'] . " >" . $lang_picinfo['remFav'] . '</a>';
}
But now I get the error:
Warning: in_array(): Wrong datatype for second argument in /home/ibn/website/fotoboek/displayimage.php on line 235link to my album: http://w3.frw.rug.nl/ibn/fotoboek/
You need to replace all files when doing an upgrade. Keeping old files will give you errors.
Quote from: Nibbler on February 26, 2005, 07:03:26 PM
You need to replace all files when doing an upgrade. Keeping old files will give you errors.
I editted the theme.php and that's causing the trouble I guess. The problem is that I editted so much that I can't undo this change.
I only want the possibility to add pictures to a favorite list. That is working, I only get the error...
You need to make sure there is an ipinfo block in theme.php - that's the problem. You can copy it over from any of the other theme.php files.
Thnx, that solved the problem!
There was some more code I had to add, but it seems to be working fine ;D