Pagination Problems

Permalink
Hi I am having some problems.

I am not sure if this is a package problem?, or the because I have friendly urls on?

I have the testimonial Block installed on the next link i get

http://mysite.com/index.php/testimonials/view//2?&ccm_paging_p=...

The link appears to be missing the first query string?

I have QSA within my HTaccss file but as it stands this is not picking up any $_GET values

Has anyone else had this problem or can help.

Thanks Sean

 
defunct replied on at Permalink Reply
defunct
The URL provided is in the correct form and works on the latest version of Concrete5 as I showed you in the email.

I have the default pretty URLs turned on, so this must be a QSA issue?
Realnet replied on at Permalink Reply
Defunct thank you for your quick response

My HTaccess contains the following

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [QSA,L]
</IfModule>


I have just noticed the url of the page above is incorrect, and this appears to be whats breaking it, the testimonial page appears within the site as a sub-page,

If I move the testimonials page to the top level it works fine.

its true url is

http://mysite.com/index.php/why-us/testimonials/...

but on clicking a pagination link it forwards to the link mentioned above stripping out the /why-us/

The QSA, stands for Query String Append and is normally added to the htaccess file to provide a way to pass through query strings.

The link shows as
http://mysite.com/index.php/testimonials/view//2?&ccm_paging_p=...

but the site refreshes and then remains as
http://mysite.com/index.php/why-us/testimonials/...

If I add the
view//2?&ccm_paging_p=2 to the end of the url the page loads.

So from what I can tell the $paginator appears to be getting the incorrect linkURL when forming the link?
Realnet replied on at Permalink Reply
I think I have solved it

I have to edit the base url that is passed through to the pagination class within testimonials.php
$pageBase = View::url('/why-us/testimonials', 'view');


this sorts the problem,
on a quick question though is it possible to grab the base url without needing to change this manually? assuming that I need to move the block to the contact-us page at a later date, or will I need to re-edit the testimonials.php page?
RadiantWeb replied on at Permalink Reply
RadiantWeb
$BASE_URL = BASE_URL;
$url = Loader::helper('navigation')->getLinkToCollection($c);
$fullUrl = $BASE_URL.$url;
Articulon replied on at Permalink Reply
Chad,
in your response at:
http://www.concrete5.org/community/forums/customizing_c5/pagination...

You give a code string. Do I replace the $pageBase = View::url('/testimonials', 'view'); with that code or add it before/after that line?

thanks,
simon8or replied on at Permalink Reply
Is there a way to show all the testimonials on one page. I've tried changing the amount of testimonials to show and it only shows a random testimonial. Any suggestions?