Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- class MyClass {
- const DB_NAME = "MyDb";
- const HOST = "localhost";
- const USER = "abcdef";
- const PASSWORD = "ghijklmn";
- protected static $MyString;
- public static function getString() {
- if (self::$MyString == null)
- self::$MyString = file_get_contents('log.txt');
- return self::$MyString;
- }
- }
- echo MyClass::getString();
- ?>
Add Comment
Please, Sign In to add comment