<commit_before><?php

use yii\helpers\Html;

use yii\widgets\ListView;
use yii\web\UrlManager;

use frontend\modules\bbii\AppAsset;
$assets = AppAsset::register($this);

/* @var $this MemberController */
/* @var $userData BbiiMember */
/* @var $dataProvider ActiveDataProvider BbiiPost */
/* @var $topicProvider ActiveDataProvider BbiiTopic*/

$this->context->bbii_breadcrumbs = array(
	Yii::t('BbiiModule.bbii', 'Forum')   => array('forum/index'),
	Yii::t('BbiiModule.bbii', 'Members') => array('member/index'),
	$userData->getAttribute('member_name') . Yii::t('BbiiModule.bbii', '\'s profile'),
);

$item = array(
	array('label' => Yii::t('BbiiModule.bbii', 'Forum'), 	'url' => array('forum/index')),
	array('label' => Yii::t('BbiiModule.bbii', 'Members'), 	'url' => array('member/index')),
	array('label' => Yii::t('BbiiModule.bbii', 'Approval'), 'url' => array('moderator/approval'), 	'visible' => $this->context->isModerator()),
	array('label' => Yii::t('BbiiModule.bbii', 'Posts'), 	'url' => array('moderator/admin'), 		'visible' => $this->context->isModerator()),
);

?>

<?php /*if (Yii::$app->user->hasFlash('notice')): ?>
<div class = "flash-notice">
	<?php echo Yii::$app->user->getFlash('notice'); ?>
</div>
<?php endif;*/ ?>

<div id = "bbii-wrapper">
	<?php echo $this->render('_header', array('item' => $item)); ?>
	
	<?php
	if ($this->context->isModerator() || $userData->getAttribute('id') == Yii::$app->user->id) {
		//echo Html::htmlButton(Yii::t('BbiiModule.bbii', 'Edit profile'), array('class' => 'bbii-button-right', 'onclick' => 'js:document.location.href = "' . Yii::$app->urlManager->createAbsoluteUrl('member/update', array('id' => $userData->getAttribute('id)) .'"'));
		echo Html::submitButton(Yii::t('BbiiModule.bbii', 'Edit profile'),
			array(
				'class' => 'btn btn-success',
				'onclick' => 'js:document.location.href = "' . Yii::$app->urlManager->createAbsoluteUrl('forum/member/update', array('id' => $userData->getAttribute('id'))) .'"'
			)
		);
	}; ?>
	
	<div class = "bbii-box-top"><?php echo Html::encode($userData->getAttribute('member_name')) . Yii::t('BbiiModule.bbii', '\'s profile'); ?></div>
	<table class = "profile"><tr><td><commit_msg>Iteration of yii buttons adding class options<commit_after><?php

use yii\helpers\Html;

use yii\widgets\ListView;
use yii\web\UrlManager;

use frontend\modules\bbii\AppAsset;
$assets = AppAsset::register($this);

/* @var $this MemberController */
/* @var $userData BbiiMember */
/* @var $dataProvider ActiveDataProvider BbiiPost */
/* @var $topicProvider ActiveDataProvider BbiiTopic*/

$this->context->bbii_breadcrumbs = array(
	Yii::t('BbiiModule.bbii', 'Forum')   => array('forum/index'),
	Yii::t('BbiiModule.bbii', 'Members') => array('member/index'),
	$userData->getAttribute('member_name') . Yii::t('BbiiModule.bbii', '\'s profile'),
);

$item = array(
	array(
      'label'   => Yii::t('BbiiModule.bbii', 'Forum'),
      'url'     => array('forum/index'),
      'options' => array(
        'class' =>'btn btn-warning'
      )
    ),
	array(
      'label' => Yii::t('BbiiModule.bbii', 'Members'),
      'url'   => array('member/index'),
      'options' => array(
        'class' =>'btn btn-warning'
      )
    ),
	array(
      'label' => Yii::t('BbiiModule.bbii', 'Approval'),
      'url'   => array('moderator/approval'), 'visible' => $this->context->isModerator(),
      'options' => array(
        'class' =>'btn btn-warning'
      )
    ),
	array(
      'label' => Yii::t('BbiiModule.bbii', 'Posts'),
      'url' => array('moderator/admin'), 'visible' => $this->context->isModerator(),
      'options' => array(
        'class' =>'btn btn-warning'
      )
    ),
);

?>

<?php /*if (Yii::$app->user->hasFlash('notice')): ?>
<div class = "flash-notice">
	<?php echo Yii::$app->user->getFlash('notice'); ?>
</div>
<?php endif;*/ ?>

<div id = "bbii-wrapper">
	<?php echo $this->render('_header', array('item' => $item)); ?>
	
	<?php
	if ($this->context->isModerator() || $userData->getAttribute('id') == Yii::$app->user->id) {
		//echo Html::htmlButton(Yii::t('BbiiModule.bbii', 'Edit profile'), array('class' => 'bbii-button-right', 'onclick' => 'js:document.location.href = "' . Yii::$app->urlManager->createAbsoluteUrl('member/update', array('id' => $userData->getAttribute('id)) .'"'));
		echo Html::submitButton(Yii::t('BbiiModule.bbii', 'Edit profile'),
			array(
				'class' => 'btn btn-success',
				'onclick' => 'js:document.location.href = "' . Yii::$app->urlManager->createAbsoluteUrl('forum/member/update', array('id' => $userData->getAttribute('id'))) .'"'
			)
		);
	}; ?>
	
	<div class = "bbii-box-top"><?php echo Html::encode($userData->getAttribute('member_name')) . Yii::t('BbiiModule.bbii', '\'s profile'); ?></div>
	<table class = "profile"><tr><td>
{'fraction_non_alphanumeric': 0.24381032312211498, 'fraction_numerical': 0.0, 'mean_word_length': 4.708982035928144, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 127, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, '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': '5248494', 'n_tokens_mistral': 1771, 'n_tokens_neox': 1747, 'n_words': 277}