per page, with , order by , clip by
Results of 1 - 6 of about 6 for CommentForm (0.027 sec.)
ウィジェット — Django 6.1 ドキュメント 11168
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ウィジェット ¶ ウィジェットは、Django が HTML の input 要素の表現方法です。ウィジェットは、HTML のレンダリングをコントロールして、ウィジェットに合致 ... ルドに別のウィジェットを使用したい場合は、フィールド定義で widget 引数を使用できます。例えば: from django import forms class CommentForm ( forms . Form ): name = forms . CharField () url = forms . URLField () comment = forms . CharField ( widget = forms . Tex ... S ファイルにいくつか記述を追加する必要もあります)。 たとえば、以下のフォームを取り上げます: from django import forms class CommentForm ( forms . Form ): name = forms . CharField () url = forms . URLField () comment = forms . CharField () このフォームには、名 ... put ウィジェットが含まれます。それぞれにはデフォルトのレンダリングが適用され、CSS クラスや追加の属性はありません。 >>> f = CommentForm ( auto_id = False ) >>> print ( f ) <div>Name:<input type="text" name="name" required></div> <div>Url:<input type="url" na ...
https://man.mtool.work/django/6.1/ref/forms/widgets.html
フォーム フィールド — Django 6.1 ドキュメント 10474
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム フィールド ¶ class Field [ソース] ¶ Form クラスを作成時の一番重要な部分は、form のフィールド (field) の定義です。各フィールドにはカスタムの ... 装する Form の完全な例です。出力を簡略化するために、 auto_id=False を指定しています: >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( label = "Your name" ) ... url = forms . URLField ( label = "Your website" ... , required = False ) ... comment = forms . CharField () ... >>> f = CommentForm ( auto_id = False ) >>> print ( f ) <div>Your name:<input type="text" name="name" required></div> <div>Your website:<input ... 、あるフィールドが特定の値で初期化された「空」のフォームを表示したい場合です。例えば: >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( initial = "Your name" ) ... url = forms . URLField ( initial = "https://" ...
https://man.mtool.work/django/6.1/ref/forms/fields.html
ウィジェット — Django 6.1 ドキュメント 10126
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » ウィジェット ¶ ウィジェットは、Django が HTML の input 要素の表現方法です。ウィジェットは、HTML のレンダリングをコントロールして、ウィジェットに合致 ... ルドに別のウィジェットを使用したい場合は、フィールド定義で widget 引数を使用できます。例えば: from django import forms class CommentForm ( forms . Form ): name = forms . CharField () url = forms . URLField () comment = forms . CharField ( widget = forms . Tex ... S ファイルにいくつか記述を追加する必要もあります)。 たとえば、以下のフォームを取り上げます: from django import forms class CommentForm ( forms . Form ): name = forms . CharField () url = forms . URLField () comment = forms . CharField () このフォームには、名 ... put ウィジェットが含まれます。それぞれにはデフォルトのレンダリングが適用され、CSS クラスや追加の属性はありません。 >>> f = CommentForm ( auto_id = False ) >>> print ( f ) <div>Name:<input type="text" name="name" required></div> <div>Url:<input type="url" na ...
https://man.mtool.work/django/6.1/ref/forms/widgets.html
フォーム フィールド — Django 6.1 ドキュメント 9779
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム フィールド ¶ class Field [ソース] ¶ Form クラスを作成時の一番重要な部分は、form のフィールド (field) の定義です。各フィールドにはカスタムの ... 装する Form の完全な例です。出力を簡略化するために、 auto_id=False を指定しています: >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( label = "Your name" ) ... url = forms . URLField ( label = "Your website" ... , required = False ) ... comment = forms . CharField () ... >>> f = CommentForm ( auto_id = False ) >>> print ( f ) <div>Your name:<input type="text" name="name" required></div> <div>Your website:<input ... 、あるフィールドが特定の値で初期化された「空」のフォームを表示したい場合です。例えば: >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( initial = "Your name" ) ... url = forms . URLField ( initial = "https://" ...
https://man.mtool.work/django/6.1/ref/forms/fields.html
フォーム API — Django 6.1 ドキュメント 6617
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム API ¶ このドキュメントについて このドキュメントでは、Django のフォーム API の詳細について説明します。このドキュメントを読む前に フォームにつ ... ドレベルとフォームインスタンスレベルの両方で initial が提供され、後者が優先されます。 >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( initial = "class" ) ... url = forms . URLField () ... comment = forms . C ... harField () ... >>> f = CommentForm ( initial = { "name" : "instance" }, auto_id = False ) >>> print ( f ) <div>Name:<input type="text" name="name" value="ins ... en dealing with callables whose return values can change (e.g. datetime.now or uuid.uuid4 ): >>> import uuid >>> class UUIDCommentForm ( CommentForm ): ... identifier = forms . UUIDField ( initial = uuid . uuid4 ) ... >>> f = UUIDCommentForm () >>> f . get_ ...
https://man.mtool.work/django/6.1/ref/forms/api.html
フォーム API — Django 6.1 ドキュメント 6617
Django 6.1 ドキュメント Home | Table of contents | Index | Modules « previous | up | next » フォーム API ¶ このドキュメントについて このドキュメントでは、Django のフォーム API の詳細について説明します。このドキュメントを読む前に フォームにつ ... ドレベルとフォームインスタンスレベルの両方で initial が提供され、後者が優先されます。 >>> from django import forms >>> class CommentForm ( forms . Form ): ... name = forms . CharField ( initial = "class" ) ... url = forms . URLField () ... comment = forms . C ... harField () ... >>> f = CommentForm ( initial = { "name" : "instance" }, auto_id = False ) >>> print ( f ) <div>Name:<input type="text" name="name" value="ins ... en dealing with callables whose return values can change (e.g. datetime.now or uuid.uuid4 ): >>> import uuid >>> class UUIDCommentForm ( CommentForm ): ... identifier = forms . UUIDField ( initial = uuid . uuid4 ) ... >>> f = UUIDCommentForm () >>> f . get_ ...
https://man.mtool.work/django/6.1/ref/forms/api.html
PREV 1 NEXT