Witam, mam problem z modułem ajaxu, mianowicie identyczny problem:
Stworzyłem moduł ajax, kontroler "changes" i dodałem defaultSection, kod popua:
<li><a id="changesModal2" href="index.php?app=goldPanel&module=ajax§ion=changes">Ostatnie zmiany</a></li>
<script type='text/javascript'>
$('changesModal2').observe( 'click', function(e) {
_var = new ipb.Popup( 'changesModalWindow', { type: 'pane',
hideAtStart: false,
modal: true,
ajaxURL: $(this).readAttribute('href'),
w: '750px',
h: 600});
Event.stop(e);
return false;
});
</script>
Plik changes.php:
<?php
if ( ! defined( 'IN_IPB' ) )
{
print "<h1>Incorrect access</h1>You cannot access this file directly. If you have recently upgraded, make sure you upgraded 'admin.php'.";
exit();
}
class public_goldPanel_ajax_changes extends ipsAjaxCommand
{
public function doExecute( ipsRegistry $registry )
{
$this->lang->loadLanguageFile( array( 'public_lang' ), 'goldpanel' );
return $this->returnHtml( $this->registry->output->getTemplate('goldPanel')->changes() );
}
}
ss: