CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • When updating PCP page-fatal error occurs, page is redirected to website Home pg
Pages: [1]

Author Topic: When updating PCP page-fatal error occurs, page is redirected to website Home pg  (Read 332 times)

lauriejtaylor

  • I’m new here
  • *
  • Posts: 1
  • Karma: 0
  • CiviCRM version: 3.4.8
  • CMS version: drupal 6.2.8
  • MySQL version: 5.1.54
  • PHP version: 5.3.4
When updating PCP page-fatal error occurs, page is redirected to website Home pg
April 07, 2014, 01:38:51 pm
One of our users created a PCP page which he wanted to change.  When he entered save he was redirected to the site's homepage.

I am not sure if this problem is corrected in a later version of Civicrm but I could not recreate it on the demo site.
The log from my site gave me a backtrace  which I have included as an attachment as well as the error.  I checked the code and found something which may or may not be a discrepancy with the function - getFieldValue.   
The function code found in civicrm/CRM/Core/DAO.php
line 716----
    static function getFieldValue( $daoName, $searchValue, $returnColumn = 'name', $searchColumn = 'id' )
code from civicrm/CRM/Contribute/Form/PCP/PCP.php
line 77 ----
 //do not allow destructive actions without permissions
        $permission = false;
        if ( CRM_Core_Permission::check( 'administer CiviCRM' ) ||
             ( $userID && ( CRM_Core_DAO::getFieldValue( 'CRM_Contribute_DAO_PCP',
                                                         $this->_id ,
                                                         'contact_id') == $userID ) ) ) {

            $permission = true;
        }
        if ( $permission && $this->_id ) {

            require_once 'CRM/Contribute/BAO/PCP.php';
            $this->_title = CRM_Core_DAO::getFieldValue( 'CRM_Contribute_DAO_PCP', $this->_id, 'title' );
            switch ( $this->_action )


It looks like PCP.php is missing a variable in the call to function getFieldValue.  If this is the case,  what is the missing value? 

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviContribute (Moderator: Donald Lobo) »
  • When updating PCP page-fatal error occurs, page is redirected to website Home pg

This forum was archived on 2017-11-26.