Skip to content
Weril

Weril

Weril

  • Nets
  • Coding
  • Linux
  • Misc
  • Life
  • About

Category: Classes

PHP Classes

Пример работы классов – из скрипта test1.php запускается медот f1 класса class1 в скрипте class1.php.
class1.php
<?php
class class1 {
  function f1() {
  echo ("Hello");
  }
}
?>

test1.php
<?php
include_once ("class1.php");
$a = new class1;
$a->f1();
?>


Читать дальше
Posted on September 6, 2016April 9, 2017Categories Classes, PHPLeave a comment on PHP Classes
Proudly powered by WordPress