HEX
Server: Apache
System: Linux v38079.2is.nl 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64
User: democfellows (10015)
PHP: 8.1.34
Disabled: opcache_get_status
Upload Files
File: /var/www/vhosts/creativefellows.nl/mygeomil.creativefellows.nl/12052025/src/Domain/Data.php
<?php

namespace App\Domain;


abstract class Data
{
		
	function __construct($data =null)
	{
		foreach((array) $data as $key => $val)
		{
			$this->$key = $val;
		}
		
	}
	
	public function set(array $data)
	{
		foreach((array) $data as $key => $val)
		{
			$this->$key = $val;
		}
		
	}
	
	public function html($string)
	{
		return htmlspecialchars($string, ENT_QUOTES, 'UTF-8');
	}
	
	/*public function price($format=true)
	{
		return $format === true ? number_format($this->sales_price,2,',','.') : $this->sales_price;
	}*/
	
	public function setDeleteUrl($url)
	{
		$this->deleteUrl = $url;
	}
	
	public function actionUrl()
	{
		return $this->deleteUrl;
	}
	
	public function price($price)
	{
		return number_format($price,2,',','.');
	}
	
	public function ceil( $value)
	{
		return ceil(round($value * 100)) / 100;
	}
	
	public function url()
	{
		return $this->url;		
	}
		
	public function setUrl($url)
	{
		$this->url = $url;
	}
	
	
}