public static function set( $key, $value, &$arr ) 
	{	
		if ( strpos( $key, '.' ) === false ) 
		{
			$arr[$key] = $value;

		} 
		else 
		{
			$kp = explode( '.', $key );

			switch ( count( $kp ) ) 
			{
				case 2:
					$arr[$kp[0]][$kp[1]] = $value; break;
				case 3:
					$arr[$kp[0]][$kp[1]][$kp[2]] = $value; break;	
				case 4:
					$arr[$kp[0]][$kp[1]][$kp[2]][$kp[3]] = $value; break;

				// if there are more then 4 parts loop trough them
				default:
					$kp = array_reverse( $kp );
					$curr = $value;

					foreach( $kp as $k ) 
					{
						$curr = array( $k => $curr );
					}

					$arr = static::merge( $arr, $curr );
				break;
			}
		}
		return $arr;
	}