La funzione showInfo(); è nella pagina principale, ho tutto nella stessa pagina.

Per quanto riguarda la domanda sul tag href, non ho nessun tag href impostato, dici che dovrei provare una cosa del genere?

Codice PHP:
<a href onclick="showInfo('database/aaaa01.jpg');">[img]database/aaaa01.jpg[/img]</a
Grazie.