JSON Javascript highlighting in Visual Studio 2010 - json

Does anybody know how to get VS 2010 to use the same highlighting for a file called .JSON as it uses for a JavaScript file? Just working on a client site and they've named all their JSON template files as .JSON, with the result that I just get a plain old text editor when I open it in Visual Studio. Any suggestions? I'm sure there must be an option somewhere that would do it but I can't find it so far...

Tools -> Options -> Text Editor -> File Extension
End your extension 'json' and select 'Script Editor' and click 'add'.
Re-open any json documents for it to take affect.

Another option is to use Text Highlighter (extention for Visual Studio 2010), which offers syntax highlighting for the following text formats:
.json (also offer syntax validation)
.bat
.cmd
.ini
.txt
.log

Great news!
In CTP2 of Visual Studio 2013 Update 2 that was added a New JSON project item and editor

Related

Edmx generate model file with blank lines

How can I configure the code Generation in VisualStudio 2015 using Database first to not generate extra blank lines in my model?
multiple people are working on this project and the source control system really don't like it :(
Maybe the solution could be to configure GIT to ignore white space?
see what the merge tool show me
It can be because of T4 file generator. Open with Notepad++ your emdx .tt file, go to Edit -> EOL Conversion -> Windows (CR LF).
Check this answer.

Visual Studio Project Template with Custom HTML Element Intellisense

Is there a way to create a Visual Studio project template that provides Intellisense for custom HTML elements? I know I can add the xsd to the commonHTML schema, but i'd prefer it only be available for my project type.
Thanks for the help!
Create a separate .xsd file (dont change the existing one) and add it to the "C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Packages\schemas\html" folder.
Then copy and paste this to a .reg file (change http://schemas.microsoft.com/intellisense/ctrls to your own namespace), and run it.
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\12.0_Config\Packages\{1B437D20-F8FE-11D2-A6AE-00104BCC7269}\Schemas\http://schemas.microsoft.com/intellisense/ctrls]
"File"="html\\your_file.xsd"
"Friendly Name"="Your Name"
"IsBrowseable"=dword:00000001
Then you can select it for your project in the drop down list with target schemas for validation.

SublimeText 2 web.config xml formatting

I have moved 90% of my development IDE work to SublimeText. The more I use it, the more I love its simplicity.
I am not able to figure out how to set code formating / coloring for different file extensions. How can I let subllimeText know .config files are xml files?
You can set this with:
Open your .config file
View -> Syntax -> Open all with current extension as... -> XML

How do I enable code formatting for JSON in Zend Studio?

I would like to enjoy code formatting for .json files in Zend Studio. I have tried associating the .json extension with the JavaScript editor, but this has no effect, and Ctrl+Shift+F simply does nothing.
How can I achieve what I want?
You have to add the file types in "Content Types" as well as in "File Associations", as in:
https://support.zend.com/hc/en-us/articles/203838106-How-to-Add-File-Types-to-the-PHP-Editor

Format Eclipse code snippets for blog publishing?

Visual Studio has a plugin that allows one to copy code from any editor (C#, HTML, XML) and then paste it with HTML formatting that preserves the syntax highlighting, etc.
This is very handy for publishing code samples/examples to a wep page/blog. I have seen one old (2006?) plugin for java to html conversion, but are there any broader solutions similar to the Visual studio plugin.
Really what I am looking for is a way to select and copy a syntax-colored block of text in Eclipse and paste it as formatted html+css.
Does such a thing exist?
Eclipse based solutions
Use the Java2Html plugin (this is maybe the plugin you were referring to):
This tool converts Java source code to HTML, XHTML and LaTeX with syntax highlighting.
There is also the CodeSnippet plugin:
CodeSnippet is a set of Eclipse plug-ins to convert Ant, Java, Properties, CSS, DTD, HTML, and XML source code (complete files or snippets) to HTML with syntax highlighting
Non Eclipse based
Use the online Source Code Formatter for Blogger, Blogspot, Blog & Blogging, Format Formatting Tool:
Source Code Beautifier And Formatter For Blogger and Websites, Format Source Code , Format Source code for blog or blogging & website, Online line source code formatter tool, blogger code format tool, Format source code for blogspot,Insert formatted source code
Although I don't know of such plug-ins, but generally pasting the syntax-highlighted text into Word or OpenOffice maintains its formatting, so using their HTML export (possibly the one of OpenOffice is useful here, as it provides simpler result, AFAIK).
The Copy as HTML eclipse IDE plugin allows us to directly copy our code as HTML and paste it to our blogs or forums without any formatting.
Steps to install the plugin:
Download the Copy as HTML eclipse plugin Copy it to the 'dropins' folder of your eclipse installation If 'dropins' folder is not present then copy it to the 'plugins' folder of your eclipse installation Restart eclipse IDE That's it