scottybowl Posted December 16, 2006 Share Posted December 16, 2006 Hi,I've recently gone back to an old project which has about 300 files, unfortunately for me, I didn't back up the files and they got lost along the way so I had to download them off the server. The problem is that all the files have had the formatting removed.Basically, I need a program which will go through all the files and automatically format the PHP and HTML contained within them so that I can read the code!Any help would be greatly appreciated, I've got to make the changes by monday so need to get them formatted ASAP. I've found a few formatters but none of them also format the HTML code.A PHP script would also do the job.. Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/ Share on other sites More sharing options...
.josh Posted December 16, 2006 Share Posted December 16, 2006 The php help forum is for asking for help when you get stuck writing your own code. For now, I'm moving this to the misc. forum as it seems like you are hoping there is some 3rd party script out there someone might be able to recommend for you. However, if you are looking for someone to write the code for you, you might try making a post in the freelance forum (please read the guidelines before posting). Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-142506 Share on other sites More sharing options...
wildteen88 Posted December 16, 2006 Share Posted December 16, 2006 What editor are you using? Prehaps its a character encoding issue. Attach one of the files here so I can see what you mean. Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-142520 Share on other sites More sharing options...
scottybowl Posted December 17, 2006 Author Share Posted December 17, 2006 i'm using dreamweaver 8, it was originally written in ultraedit. The code has been put onto one long line with all the formatting removed - I've had to to resort to manually putting the formatting back in, not much fun when scripts turn out to be over 800 lines long each :| Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-142881 Share on other sites More sharing options...
AndyB Posted December 17, 2006 Share Posted December 17, 2006 http://www.bierkandt.org/beautify/ Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-142968 Share on other sites More sharing options...
Philip Posted December 17, 2006 Share Posted December 17, 2006 Also, on htmlkit (the editor I use) there is an extension that cleans up and indents all coding :) Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-143102 Share on other sites More sharing options...
Daniel0 Posted December 17, 2006 Share Posted December 17, 2006 [quote author=KingPhilip link=topic=118889.msg486816#msg486816 date=1166389419]Also, on htmlkit (the editor I use) there is an extension that cleans up and indents all coding :)[/quote]I remember having used htmlkit before... It doesn't have support for heredoc, right? Well I don't know about know... Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-143114 Share on other sites More sharing options...
c4onastick Posted December 18, 2006 Share Posted December 18, 2006 [quote author=KingPhilip link=topic=118889.msg486816#msg486816 date=1166389419]Also, on htmlkit (the editor I use) there is an extension that cleans up and indents all coding :)[/quote]I didn't know things like that existed! I was going to suggest you "roll your own", I had a bunch of sed files all lined up in my head to take care of that. Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-143403 Share on other sites More sharing options...
Philip Posted December 18, 2006 Share Posted December 18, 2006 Yup, keIndentPHPCodecan be found here: http://www.chami.com/html-kit/plugins/info/keindentphpcode/ Quote Link to comment https://forums.phpfreaks.com/topic/30894-php-code-formatter-needed/#findComment-143714 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.