# Source Menu

The Source menu allows you to organize your scripts by adding or removing comments and formatting the script to make it more easily viewable.

The options available from the Source menu are:

Name | Shortcut | Description
--- | --- | ---
Toggle Comment | Ctrl+/ -or- Ctrl+7 | Comments or uncomments a line by adding or removing "//" characters. Comments are used for adding text to your script to explain sections of code. Commented text will not be run as part of your code. To use this feature, select the line and press Ctrl+/. For more, see " Commenting Code ."
Add Block Comment | Ctrl+Shift+/ | Comments a block by adding "/*" and "*/" characters to either side of the code. To use this feature, select the block and press Ctrl+Shift+/. For more, see " Commenting Code ."
Remove Block Comment | Ctrl+Shift+\ | Removes a block comment. To use this feature, place the cursor anywhere within the comment and click Ctrl+Shift+\. For more, see " Commenting Code ."

Format Document

Ctrl+Shift+F

Auto formats a script to organize it into an easily readable format.
To format your code, place your cursor anywhere within the editor view and press Ctrl+Shift+F. Appropriate line breaks and indents will be added.
You can configure your auto-formatting options through the Formatter Preferences page , accessible from Window | Preferences | PHP | Formatter. For more, see Formatting Code .

Format Active Elements | Ctrl+I | Only formats selected code. To format active elements, select the required code to format and press Ctrl+I. Appropriate line breaks and indents will be added to the active elements. You can configure your auto-formatting options through the Formatter Preferences page , accessible from Window | Preferences | PHP | Formatter. For more, see Formatting Code .

#### Related Links:

- Menus
- File
- Edit
- Refactor
- Navigate
- Search
- Project
- Run
- Window
- Help