Jump to content
TNG Community

Comments Mod v14.0.0.2d displays text from comments_add.php


Chris-Korte

Recommended Posts

Chris-Korte

When I install Comments Mod v14.0.0.2d on my working website, text as shown in attached image displays at the top of getperson page, but the Comments section does not appear.  The text appears to come from ../mods/comments_v14.0.0.2d/comments_add.php.  The same mod installed on my test site (Wampserver on windows 11) displays correctly on the getperson page.

A review of the getperson code on both my website and test site shows that the Comments Mod is installed the same (as shown below from extracts of getperson.php). 

Any suggestions how I can get to the mod to display correctly on my working website appreciated.

Thanks

 

*********** From site where Mod does not work

			$persontext .= endSection("notes");
		}
	}

/* START MOD: Comments v13.0.0.2a (1/1) */

$commentsPersonOn = true;
$allowCommentsOnLivingAndPrivatePersons = true;

if ($commentsPersonOn && ((!$row['living'] && !$row['private']) || $allowCommentsOnLivingAndPrivatePersons)) {
	$type = "persfam";
	$comment = getComments($personID, $tree, $type);
	if ($comment[0] || $currentuser || $commentsPublic || $commentsAlwayson) {
		$persfamplaID = $personID;
		$pnn = $namestr;

// Start New v13.0.0.2a
		$pnn = str_replace("'", "'", $pnn);
// End New v13.0.0.2a

		include $cms['tngpath'] . "comments_add.php";
		$persontext .= "<br/>\n";
	}
}

/* END MOD: Comments v13.0.0.2a (1/1) */


	if( $citedispctr ) {

 

*********** From Test site where Mod works

            $persontext .= endSection("notes");
        }
    }

/* START MOD: Comments v13.0.0.2a (1/1) */

$commentsPersonOn = true;
$allowCommentsOnLivingAndPrivatePersons = true;

if ($commentsPersonOn && ((!$row['living'] && !$row['private']) || $allowCommentsOnLivingAndPrivatePersons)) {
    $type = "persfam";
    $comment = getComments($personID, $tree, $type);
    if ($comment[0] || $currentuser || $commentsPublic || $commentsAlwayson) {
        $persfamplaID = $personID;
        $pnn = $namestr;

// Start New v13.0.0.2a
        $pnn = str_replace("'", "&#039;", $pnn);
// End New v13.0.0.2a

        include $cms['tngpath'] . "comments_add.php";
        $persontext .= "<br/>\n";
    }
}

/* END MOD: Comments v13.0.0.2a (1/1) */


    if( $citedispctr ) {

Screenshot 2024-07-21 160403.png

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...