# Code Cleaner?

**URL:** <https://forum.kirupa.com/t/code-cleaner/9330>\
**Category:** programming\
**Created:** [December 9, 2002, 11:47pm UTC](https://forum.kirupa.com/t/code-cleaner/9330 "2002-12-09T23:47:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ask](https://avatars.discourse-cdn.com/v4/letter/a/df705f/32.png) [@ask](https://forum.kirupa.com/u/ask)\
**Post date:** [December 9, 2002, 11:47pm UTC](https://forum.kirupa.com/t/code-cleaner/9330/1 "2002-12-09T23:47:27Z")

</div>

Anyone know any ready made programs that clean code up? You know something to run code thru to format it coherently. I think I’m going to make my own, but if there is something already made for this it would save a lot of time.

I hate when people code like this:

```php

if(var)

{

                  int a = 5;
}

```

Something to convert code like that into

```php

if(var){
   int a=5;
}

```

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [December 10, 2002, 12:17am UTC](https://forum.kirupa.com/t/code-cleaner/9330/2 "2002-12-10T00:17:39Z")

</div>

People actually code like that? They should be shot (watch…my coding probly looks like that…)

I know there is something that cleans up HTML, but I don’t know about anything else… here is the link to that…

[http://www.w3.org/People/Raggett/tidy/](http://www.w3.org/People/Raggett/tidy/)

I would try a search on google… you may come up with something

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)\
**Post date:** [December 10, 2002, 5:23am UTC](https://forum.kirupa.com/t/code-cleaner/9330/3 "2002-12-10T05:23:22Z")

</div>

I’ve used tidy. It works well for html and decent for php, but I was looking for one for C++
