# Extend the Comment Form Let's assume we create a Blog-Package and have to add an optional phone field to the comment form. **Add the new Property to the NodeType and Inspector Section** _Vendor.Blog/Configuration/NodeTypes.Comment.yaml_ 'WebExcess.Comments:Comment': properties: phone: type: string ui: inlineEditable: false label: 'Vendor.Blog:NodeTypes.Comment:properties.phone' reloadIfChanged: true inspector: group: 'comment' editorOptions: maxlength: 50 **Create a custom Comment-Model which includes the new Property** _Vendor.Blog/Classes/Vendor/Blog/Domain/Model/Comment.php_ phone; } /** * @param string $phone */ public function setPhone($phone) { $this->phone = $phone; } } **Replace the original Comment-Model with your version** _Vendor.Blog/Classes/Vendor/Blog/Configuration/Objects.yaml_ WebExcess\Comments\Domain\Model\CommentInterface: className: 'Vendor\Blog\Domain\Model\Comment' **Point to your custom Templates** _Vendor.Blog/Configuration/Views.yaml_ - requestFilter: 'isPackage("WebExcess.Comments") && isController("Comments")' options: templatePathAndFilename: 'resource://Vendor.Blog/Private/Templates/Comments/Index.html' partialRootPaths: ['resource://Vendor.Blog/Private/Partials/Comments'] **Copy the Base-Template and add your Form-Field** _Vendor.Blog/Resources/Private/Templates/Comments/Index.html_
**Overwrite the TextField-Partial to inject your custom Translation-File** _Vendor.Blog/Resources/Private/Partials/Comments/TextField.html_
**Add your field translation** _Vendor.Blog/Resources/Private/Translations/en/NodeTypes/Comment.xlf_ Phone **Result** Now your Blog-Package is using [webexcess/comments](https://github.com/webexcess/WebExcess.Comments) for all Feedbacks and offers an optional Phone-Formfield which is only visible to the editors. So customers can open another feedback-channel. Without ~~breaking~~ forking the original Package itself.