Skip to content

Instantly share code, notes, and snippets.

@platoosom
Created September 28, 2017 05:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save platoosom/9efaac1823997b57a0e78343ef49d52c to your computer and use it in GitHub Desktop.
Save platoosom/9efaac1823997b57a0e78343ef49d52c to your computer and use it in GitHub Desktop.
<?php
/**
* This is properties.
**/
class Post {
/**
* This is properties.
**/
$id = '';
$title = '';
$detail = '';
/**
* This is method.
**/
public function save() {
// Connect to database
// Save data to post table
// Return result
}
/**
* This is method.
**/
public function ID() {
return $this->id;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment