CMS MADE SIMPLE FORGE

CGFeedback

 

[#6631] {$origurl} not working

avatar
Created By: Leonardo R. da Rosa (lrrosa)
Date Submitted: Tue Jul 05 22:40:13 -0400 2011

Assigned To:
Version: 1.3.5
CMSMS Version: None
Severity: None
Resolution: Fixed
State: Closed
Summary:
{$origurl} not working
Detailed Description:
I can't use the tag {$origurl} in admin template with CGFeedback 1.3.5.


History

Comments
avatar
Date: 2011-07-28 03:29
Posted By: Andrea Weichbrodt (wich)

Confirmed!
There's no trace of the {$origurl} tag.
Tested with CGFeedback 1.3.5 + normal page content (no blog or news entry) +
pretty url.
This tag is very useful for the user/admin notification email, because without
it users can't retrieves the url of the commented page if the "send me
notification when new comment is added" option is on.
Please, fix it.
      
avatar
Date: 2011-07-28 20:37
Posted By: Leonardo R. da Rosa (lrrosa)

The solution I've found was to add the missing lines again to the file
"action.default.php".
On line 360, just add it inside the "if":

    // done... now handle success or failure.
    if( empty($error) )
      {
	if( isset($params['feedback_origurl']) ) // missing $origurl lines
	  {
	    $smarty->assign('origurl',$params['feedback_origurl']);
	  }

	$res = $comment->save();
	if( !$res )
	  {
	    $error = $this->Lang('error_dberror');
	  }
      }

      
avatar
Date: 2011-08-04 13:53
Posted By: Andrea Weichbrodt (wich)

In v1.3.5, Robert have deployed all the smarty assignments in the class
cgfb_comment_notifier (the file is
..\CGFeedback\lib\class.cgfb_comment_notifier.php).
I will test it adding the assignment:

   if( isset($params['feedback_origurl']) )
      {
      $smarty->assign('origurl',$params['feedback_origurl']);
      }

in the function prepare_smarty_vars of the class.

Andrea
      
avatar
Date: 2011-08-04 15:46
Posted By: Andrea Weichbrodt (wich)

mmm... it does not work.
Leonardo's solution works fine for me.
Andrea 
      
avatar
Date: 2011-09-07 04:52
Posted By: Emmanuelle Lellouche (Numastick)

Hello,

Leonardo's solution is working fine for admin's notifications, but not for users
.
Does anyone have the same problem ?

Thanks,
Emmanuelle.
      
Updates

Updated: 2012-06-22 10:36
state: Open => Closed

Updated: 2011-10-02 14:31
resolution_id: => 7
cmsms_version_id: => -1