Note that there are some explanatory texts on larger screens.

plurals
  1. POJoomla Pagination URL is excluding the view=viewname
    text
    copied!<p>I have pagination setup on a custom Joomla component. To avoid a page long explanation, we're kind of doing some intricate iframe embedding and forward masking. This is pagination for the front end of the component.</p> <p>In my iframe, I have a list of puppies (from the custom component). It is paginated. In order for the puppies to display correctly in the iframe it has to have the URL : </p> <p><a href="http://americasfavoritepuppybreeders.com/puppies/breed/labrador/page-2.html?tmpl=component&amp;view=microsite" rel="nofollow">http://americasfavoritepuppybreeders.com/puppies/breed/labrador/page-2.html?tmpl=component&amp;view=microsite</a> </p> <p>However when I actually click on the pagination link for page 2 it drops the view=microsite which causes problems. How can I adjust this so that it does not drop the view=microsite?</p> <p>The original URL is <a href="http://americasfavoritepuppybreeders.com/puppies/breed/labrador/page-1.html?tmpl=component&amp;view=microsite" rel="nofollow">http://americasfavoritepuppybreeders.com/puppies/breed/labrador/page-1.html?tmpl=component&amp;view=microsite</a></p> <p>The code for this pagination is long and between the model, view and view.html.php so it seems difficult for me to post all the related code. Here's some though where I have been looking.</p> <p>Any ideas or hints on where / how to do this?</p> <p>Thanks Zach</p> <pre><code>// Get the pagination request variables $limit = $app-&gt;input-&gt;get('limit', $params-&gt;get('display_num', 20), 'uint'); $limitstart = $app-&gt;input-&gt;get('limitstart', 0, 'uint'); $this-&gt;setState('puppies.limit', $limit); $this-&gt;setState('puppies.limitstart', $limitstart); // Load the parameters. $this-&gt;setState('params', $params); } /** Method to get a store id based on the model configuration state. **/ protected function getStoreId($id = '') { // Compile the store id. $id .= ':' . $this-&gt;getState('puppies.breed_alias'); $id .= ':' . $this-&gt;getState('puppies.limit'); $id .= ':' . $this-&gt;getState('puppies.limitstart'); $id .= ':' . serialize($this-&gt;getState('puppies.filter')); $id .= ':' . $this-&gt;getState('puppies.featured'); return parent::getStoreId($id); } /** Method to get a JPagination object for the data set. **/ public function getPagination() { // Create the pagination object. $limit = (int) $this-&gt;getState('puppies.limit'); $page = new JPagination($this-&gt;getTotal(), $this-&gt;getStart(), $limit); return $page; } /** Method to get the total number of items for the data set. **/ public function getTotal() { return $this-&gt;items_total; } /** Method to get the starting number of items for the data set. **/ public function getStart() { $start = $this-&gt;getState('puppies.limitstart'); $limit = $this-&gt;getState('puppies.limit'); $total = $this-&gt;getTotal(); if ($start &gt; $total - $limit) { $start = max(0, (int) (ceil($total / $limit) - 1) * $limit); } return $start; } </code></pre> <p>Again, a portion of the code here but I have no idea what to begin posting for an answer to this so please I will post any code but point me in the right direction, thanks.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload