<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Problemino sulla creazione di un componente]]></title><description><![CDATA[<p dir="auto">Salve, spero di postare nella sezione giusta (è la prima volta)...avrei un piccolo problema, ho scritto un mio componente per la gestione semplificata della squadre di calcio e mi da un errore.<br />
Mi spego meglio: vado dal backend e clicco sul mio componente lui mi dice</p>
<blockquote>
<p dir="auto">Fatal error: Call to a member function getListFooter() on a non-object in /var/www/intr/administrator/components/com_squadre/views/squadre/tmpl/default.php on line 45</p>
</blockquote>
<p dir="auto">Posto le porzioni dei file utilizzati</p>
<blockquote>
<p dir="auto">FILE default.php</p>
<p dir="auto">&lt;form action="index.php" method="post" name="adminForm"&gt;<br />
&lt;div id="editcell"&gt;<br />
&lt;table class="adminlist"&gt;<br />
&lt;thead&gt;<br />
&lt;tr&gt;<br />
&lt;th width="5"&gt;<br />
&lt;?php echo JText::<em>('ID'); ?&gt;<br />
&lt;/th&gt;<br />
&lt;th width="20"&gt;<br />
&lt;input type="checkbox" name="toggle" value="" onclick="checkAll(&lt;?php echo count($this-&gt;items); ?&gt; );" /&gt;<br />
&lt;/th&gt;<br />
&lt;th width="125"&gt;<br />
&lt;?php echo JText::</em>('Name'); ?&gt;<br />
&lt;/th&gt;<br />
&lt;th&gt;<br />
&lt;?php echo JText::_('Championship'); ?&gt;<br />
&lt;/th&gt;<br />
&lt;/tr&gt;<br />
&lt;/thead&gt;<br />
&lt;tfoot&gt;<br />
&lt;tr&gt;<br />
&lt;td colspan="4"&gt;<br />
&lt;?php echo $this-&gt;pagination-&gt;getListFooter(); ?&gt; //RIGA 45<br />
&lt;/td&gt;<br />
&lt;/tr&gt;<br />
&lt;/tfoot&gt;<br />
&lt;tbody&gt;</p>
</blockquote>
<blockquote>
<p dir="auto">FILE view.html.php</p>
<p dir="auto">defined('_JEXEC') or die('Restricted access');</p>
<p dir="auto">jimport('joomla.application.component.view');</p>
<p dir="auto">class SquadreViewSquadre extends JView {</p>
<pre><code>  function display($tpl = null){
      $items &amp;= $this-&gt;get('Team');
      $pagination &amp;= $this-&gt;get('Pagination');
      $this-&gt;assignRef('items', $items);
      $this-&gt;assignRef('pagination', $pagination);          
      parent::display($tpl);
    }
}
</code></pre>
</blockquote>
<p dir="auto">e infine il modello</p>
<blockquote>
<p dir="auto">FILE squadre.php</p>
<pre><code>    function &amp;getPagination() {
        if (empty($this-&gt;_pagination)) {
            jimport('joomla.html.pagination');
            $this-&gt;_pagination = new JPagination( $this-&gt;getTotal(),
                $this-&gt;getState('limitstart'), $this-&gt;getState('limit') );
        }
        return $this-&gt;_pagination;
    }
</code></pre>
</blockquote>
<p dir="auto">cosa posso fare? Anche perchè in tutta onestà mi pare di aver capito dalle varie guide online che la paginazione la gestisce lui e quindi il codice è abbastanza standard.</p>
<p dir="auto">PSarlo di Joomla 1.5<br />
Grazie Mille.</p>
<p dir="auto"><img src="https://dev.connect.gt/assets/plugins/nodebb-plugin-emoji/emoji/customizations/ad0a1f8d-b404-40e4-a46a-e563b14044da-dho.gif?v=12b9555a9a1" class="not-responsive emoji emoji-customizations emoji--arrabbiato" style="height:1.4em;width:auto;vertical-align:middle" title=":x" alt="" /></p>
]]></description><link>https://dev.connect.gt/topic/86446/problemino-sulla-creazione-di-un-componente</link><generator>RSS for Node</generator><lastBuildDate>Wed, 25 Nov 2026 20:54:44 GMT</lastBuildDate><atom:link href="https://dev.connect.gt/topic/86446.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 30 Oct 2008 14:54:59 GMT</pubDate><ttl>60</ttl></channel></rss>