You are here: PSPad forum > English discussion forum > PHP format code
Posted by: Askold | Date: 2024-03-28 14:30 | IP: IP Logged
Perhaps I don’t know such a button in the editor,
I would like to have something similar to “Format HTML” also
for “Format PHP” and for “Format Javascript”.
Posted by: pspad | Date: 2024-03-29 17:30 | IP: IP Logged
You can use any command line formatting utility and integrate it into PSPad
Posted by: Askold | Date: 2024-03-30 07:17 | IP: IP Logged
The answer is clear, but it's a pity.
Posted by: pspad | Date: 2024-03-30 07:30 | IP: IP Logged
It isn't easy develop and maintain code lexers and formater for different languages.
From this point of view is easier to integrate any existing solution, like SQLFormater for SQL e.t.c.
Posted by: Askold | Date: 2024-04-03 15:46 | IP: IP Logged
It can be easier, of course, to integrate any existing solution if you know how, and you definitely know how to do it, unlike ordinary users.
It is possible that you will need to add some modules or files.
Well, at least for PHP, and for Javascript it would be wonderful and amazing
The existing editor is the best and most convenient of all that I have tried.
And probably over time you will want to improve it somehow.
I can only wish you every success!
Posted by: cecege | Date: 2024-06-02 18:50 | IP: IP Logged
PHP-CS-Fixer: This is a command-line tool that fixes your PHP code to follow defined coding standards, such as PSR-1, PSR-2, etc. You can use it by running a command like php-cs-fixer fix /path/to/your/files.
PHP_CodeSniffer: Another tool that tokenizes PHP, JavaScript, and CSS files to detect violations of a defined coding standard. It can also automatically correct code style issues.
Pretty-php: A modern and actively maintained PHP formatter that you can use to beautify your PHP code.
Posted by: pspad | Date: 2024-06-02 19:13 | IP: IP Logged
Thank you for tools.
I will try to integrate it into PSPad
Editor PSPad - freeware editor, © 2001 - 2024 Jan Fiala, Hosted by Webhosting TOJEONO.CZ, design by WebDesign PAY & SOFT, code Petr Dvořák, Privacy policy and GDPR