<?php

if ($web_key === false)
{
	$editable = false;
}
else
{
	if (!isset ($_SESSION['sess_' . $prefix . 'Type']))
	{
		$editable = false;
	}
	else
	{
		if ($_SESSION['sess_' . $prefix . 'Type'] === 'ALL')
		{
			$editable = true;
		}
		else
		{
			if ($_SESSION['sess_' . $prefix] === '')
			{
				$editable = false;
			}
			else
			{
				$arr_rights = explode(';', $_SESSION['sess_' . $prefix]);

				foreach ($arr_rights as $navRight)
				{
					$navId = str_replace($prefix . '_', '', $navRight);
					if (in_array($navId, $pathWay))
					{
						$editable = true;
						break;
					}
				}

			}
		}
	}
}