Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Aleksey Polivanyy
1,679 PointsHow to attach code to question?
How to attach code to question?
1 Answer
Jonathan Grieve
Treehouse Moderator 91,254 Pointshi Aleksey, Welcome to Treehouse, great question too :)
There are 2 main ways.
If you're doing a code challenge on a course you can automatically attach the code you've attempted when you ask a question to a forum. This would have to be on the same page as the challenge page you're working on. You can click an option to attach the code to your post when you submit. So that's one option.
Secondly you can attach "customised" to any forum post you make by using the Markdown cheatsheet, a link to which is on any forum page.
Here it is: Markdown Cheatsheet
The main way to add code would be to use 3 backticks to open the codespace, type in the language you want to use and then 3 more backticks to close it.
like this
<p>Some HTML Code</p>
Have a look at the markdown cheatsheet whenever you're unsure about to format text n the forums. :)