https://azure.microsoft.com/ja-jp
使うにはクレジットカードが必要みたいですね
https://azure.microsoft.com/ja-jp
使うにはクレジットカードが必要みたいですね
<?php
require(‘../app/functions.php’);
include(‘../app/_parts/_header.php’);
?>
<form action=”result.php” method=”get”>
<input type=”text” name=”message”>
<button>Send</button>
</form>
<?php
include(‘../app/_parts/_footer.php’);

<?php
class Post
{
private $text;
private static $count = 0;
//private const VERSION = 0.1;
public const VERSION = 0.1;
public function __construct($text)
{
$this->text = $text;
self::$count++;
}
public function show()
{
printf(‘%s’ . PHP_EOL, $this->text);
}
public static function showInfo()
{
printf(‘Count: %d’ . PHP_EOL, self::$count);
printf(‘Version: %.1f’ . PHP_EOL, self::VERSION);
}
}
$posts = [];
$posts[0] = new Post(‘hello’);
$posts[1] = new Post(‘hello again’);
$posts[0]->show();
$posts[1]->show();
Post::showInfo();
echo Post::VERSION . PHP_EOL;

<?php
$post = [];
$posts[0] = [‘text’ => ‘hello’, ‘liles’ => 0];
$posts[1] = [‘text’ => ‘hello again’, ‘liles’ => 0];
//print_r($posts);
function show($post)
{
printf(‘%s (%d)’ . PHP_EOL, $post[‘text’], $post[‘liles’]);
}
show($posts[0]);
show($posts[1]);
https://noauto-nolife.com/post/django-makemigrations-not-applied/
Youtube見てもググっても分からなかったので本のソースコードを使いました
基本的に先にアプリを作っておくといいかもしれないですね
Djangoを習得するとWEBサービス,WEBアプリが作れそうです
test.py
from django.test import TestCase
from django.urls import resolve
from snippets.views import snippet_new, snippet_edit, snippet_detail
class CreateSnippetTest(TestCase):
def test_should_resolve_snippet_new(self):
found = resolve(“/snippets/new/”)
self.assertEqual(snippet_new, found.func)
class SnippetDetailTest(TestCase):
def test_should_resolve_snippet_detail(self):
found = resolve(“/snippets/1/”)
self.assertEqual(snippet_detail, found.func)
class EditSnippetTest(TestCase):
def test_should_resolve_snippet_edit(self):
found = resolve(“/snippets/1/edit/”)
self.assertEqual(snippet_edit, found.func)