<commit_before><?php
// $Id: /cvsroot/tikiwiki/tiki/tiki-view_tracker_item.php,v 1.141.2.24 2008-02-28 14:57:12 sylvieg Exp $
if (strpos($_SERVER["SCRIPT_NAME"],basename(__FILE__)) !== false) {
	header("location: index.php");
	exit;
}
/*
 * Smarty plugin
 * -------------------------------------------------------------
 * File:     resource.wiki.php
 * Type:     resource
 * Name:     wiki
 * Purpose:  Fetches a template from a wiki page
 * -------------------------------------------------------------
 */
function smarty_resource_wiki_source($page, &$tpl_source, &$smarty) {
	global $tikilib;

	$info = $tikilib->get_page_info($page);
	if (empty($info)) {
		return false;
	}
	$tpl_source = $tikilib->parse_data($info['data'], array('is_html' => $info['is_html'], 'print'=>'y'));
	return true;
}

function smarty_resource_wiki_timestamp($page, &$tpl_timestamp, &$smarty) {
	global $tikilib;<commit_msg>rollback 18563 + give e perm denied message. Pretty tracker wiki page needs an additional perm: this page should be not viewable (as they are construction page , but a perm check is needed as a user can use TRACKER with a forbidden page that has nothing to do with trackers<commit_after><?php
// $Id: /cvsroot/tikiwiki/tiki/tiki-view_tracker_item.php,v 1.141.2.24 2008-02-28 14:57:12 sylvieg Exp $
if (strpos($_SERVER["SCRIPT_NAME"],basename(__FILE__)) !== false) {
	header("location: index.php");
	exit;
}
/*
 * Smarty plugin
 * -------------------------------------------------------------
 * File:     resource.wiki.php
 * Type:     resource
 * Name:     wiki
 * Purpose:  Fetches a template from a wiki page
 * -------------------------------------------------------------
 */
function smarty_resource_wiki_source($page, &$tpl_source, &$smarty) {
	global $tikilib;

	$info = $tikilib->get_page_info($page);
	if (empty($info)) {
		return false;
	}
	$tpl_source = $tikilib->parse_data($info['data'], array('is_html' => $info['is_html'], 'print'=>'y'));
	return true;
}

function smarty_resource_wiki_timestamp($page, &$tpl_timestamp, &$smarty) {
	global $tikilib, $user;
	if (!$tikilib->user_has_perm_on_object($user, $page, 'wiki page', 'tiki_p_use_as_template')) {
		return 'Permission denied';
	}
{'fraction_non_alphanumeric': 0.2515865820489574, 'fraction_numerical': 0.02130553037171351, 'mean_word_length': 2.8249566724436743, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 2, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4207663', 'n_tokens_mistral': 750, 'n_tokens_neox': 703, 'n_words': 167}