[Solved (workaround)] CGFeedback stops ? page_name issue

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
Andrew Prior
Forum Members
Forum Members
Posts: 249
Joined: Sun Oct 28, 2007 4:14 am

[Solved (workaround)] CGFeedback stops ? page_name issue

Post by Andrew Prior »

I have CMS Made Simple™ 1.11.6 “Merchena” and CGFeedback 1.5.12 on LAMP.

My code is:

Code: Select all

{CGFeedback key2=$page_name action='summary' sortorder="ASC"}
 {CGFeedback key2=$page_name}
which until now has worked perfectly to display the comments on a page, and to allow the addition of more comments.

For some reason, published comments are now not being displayed. I see that key 2 is no longer being inserted into the database as the page_name but as the page number. If I use phpMyadmin to change the number back to the page_name, everything works.

Can anyone suggest what the problem might be... or even how to fix it?
Last edited by Andrew Prior on Fri Jul 26, 2013 12:47 pm, edited 1 time in total.
uniqu3

Re: CGFeedback stops displaying; something about page_name

Post by uniqu3 »

Look where {$page_name} variable comes from, obviously this changed it's behavior.
Andrew Prior
Forum Members
Forum Members
Posts: 249
Joined: Sun Oct 28, 2007 4:14 am

Re: CGFeedback stops displaying; something about page_name

Post by Andrew Prior »

Well yes. But it comes from the module itself!
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: CGFeedback stops displaying; something about page_name

Post by Jo Morg »

Andrew Prior wrote:Well yes. But it comes from the module itself!
Well I just re-read CGFeedback's help and see no mention to $page_name nor anything like it. AFAIK $page_name is not initialized nor used by the core.
My suggestion is that, if $page_name = to the alias of the page, replace $page_name by $page_alias. that should work, on a page by page basis.
HTH.
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
Andrew Prior
Forum Members
Forum Members
Posts: 249
Joined: Sun Oct 28, 2007 4:14 am

Re: CGFeedback stops displaying; something about page_name

Post by Andrew Prior »

You are correct Jo! But changing to $page_alias makes no difference. CGfeedback insists on writing the id no, not the page alias or page name. So I have taken the slow but sure method of manually updating the tables in mysql and then my templates, to take the default option. I did reinstall the module first, but to no avail. Sort of solved :-(
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1978
Joined: Mon Jan 29, 2007 4:47 pm

Re: [Solved (workaround)] CGFeedback stops ? page_name issue

Post by Jo Morg »

Andrew Prior wrote:But changing to $page_alias makes no difference. CGfeedback insists on writing the id no, not the page alias or page name.
Ok from what I could figure out from the help, it seems that for the simple purpose of having a page by page comment system you shouldn't need even that...

This should suffice:

Code: Select all

{CGFeedback action='summary' sortorder="ASC"}
 {CGFeedback}

At least according yo this:
Help wrote:
  • - (optional) key1="" - First key in the triplet of keys that make up a unique identifier for a comment list. If this parameter is not specified, then it is assumed that you are referring to a content page
  • - (optional) key2="" - Second key in the triplet of keys that make up a unique identifier for a comment list. If this parameter is not specified, the current page id will be used.
  • - (optional) key3="" - Third key in the triplet of keys that make up a unique identifier for a comment list. This parameter is entirely optional for normal use, but may be required in extenuating circumstances when two keys are not enough information to make the comment list unique.
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
Post Reply

Return to “Modules/Add-Ons”