We needed to clean things up and make it easier to find your way around. This update is the start a series of staged site updates that will bring consistency to our various areas.
Please visit our Bugs and Suggestions forum
Sharing code with others is a great way to not only help others, but also to become a better programmer. With many thousands of people downloading your code you will not only get a lot of positive feedback, but also bug fixes, free testing, and more often than not, suggestions on how to make the code even better. It also encourages others to share their code, which in turn gives you access to an even larger base of free source code.
First and foremost, we need some documentation. This doesn't have to be anything fancy, though we don't mind if it is, but if you think about answering the following questions then you should be off to a good start.
The idea is to give the reader a clear idea of the purpose of your code, instead of forcing them to download a project, build it and then hunt around to find out what the sample does. This means articles that are code snippets, with no explanation of what the snippet does, are insufficient.
First and foremost, does the code actually work? We do sometimes get code that, for one reason or another, just does not work. Please check that the source code you send compiles cleanly, and if part of a larger demo application, that the application itself runs OK.
We do ask that the general conventions be adhered for your language to so that other programmers can understand your code easily. Conventions that help other programmers read your code are:
Also, does the code compile cleanly under the warning level 4?
You can submit the article and code to in one of three ways:
From the home page, here:
At the top of the Article Submission Wizard there is a Section dropdown:
There are larger chapters, like Desktop Development, Web Development, Mobile Development, Cloud Computing, etc, and sections within those. Additionally, there is a subsection dropdown next to it on the right. Each article must have a section assigned to it. If you do not select one, the "Uncategorized Articles" will be chosen by default. Please choose the most appropriate section accordingly. If you have a section suggestion, please feel free to email us at submit[at]codeproject.com.
The URL of your article will depend on the title you give it. For example, if your title is 'coolcode' then your article's URL will be 'http://www.codeproject.com/Articles/ArticleID/coolcode'
This name is important, as it helps search engines find your article. Make sure you name it something appropriate.
300 characters or less (spaces included), on what your article's purpose. Be clear, and concise; it will decide whether or not someone reads your article.
Simply begin typing into the Tags field. As you type, a dropdown of current tags will be displayed. Select accordingly.
Also note the secondary dropdown where you can scroll through lists of languages, platforms, technologies, and audiences that apply.
If you use the dropdown to select attributes, DO NOT check the parent attribute if all the children attributes do not apply
We have a list of licenses here to help you choose the license appropriate for you and your code.
PLEASE NOTE: The only image files we accept are PNG, GIF, and JPG. Our article editor currently does not support SVG.
On the far right of the screen you will see an "Upload Files" heading. Below it you will see a dotted box that indicates "Drag and Drop Files Here." Simply drag and drop your files into that box, and its done!
Each file can be added using the yellow arrow icon as shown below. Simply place the cursor in the article area where you want the file to be located, then click the arrow to place the image/file there.
For zip files containing code there is a shortcut to adding files. Underneath "Current Files" you will see a insert button and link entitled "Add selected zip files to article." Simply click that link to automatically add neatly formatted files to your article.
If you are adding files to the article without the button, you would do the following in the HTML:
<li><a href="filname.zip">Download source - X KB</a>
If you are adding images to the article without the button, you would simply do the following. (Note: It is important to keep paths within the href free of extraneous pathway. Simply add the filename inside the quotations).
<img src="imagename.png" />
Check this teenie, tiny box:
And make sure you have saved your draft:
Later when you come back check "My Articles" here:
Later when you are ready to finish return to the submission page and access your draft from here:
Knowing HTML is the ideal for the editor. Select the HTML button to switch between HTML and WYSIWYG (What You See Is What You Get) modes. Please note, class designations (ie. table class="ArticleTable") have specific capitalization.
Use this HTML button to switch between the two modes:
<p>Paragraphs go in paragraph tags.</p>
<li>Unordered lists go in these tags</li>
<code>All your variables, class names, properties, etc. must go inside</code>
<strong>If you really want to bold something, use this tag. But we don't like it</strong>
<em>All file names inside the article must be italicized: .zip, .cs, .html, etc.</em>
<img src="imagename.png" />
Headings must be used like this
<h3>Sub Heading to h2 Heading - a Sub Topic to the Previous Topic</h3>
<h4>Sub Heading to h3 Heading - a Sub Topic to the Previous Topic</h4>
<h5>Sub Heading to h4 Heading - a Sub Topic to the Previous Topic</h5>
<div class="Caption">Captions go in this div class</div>
<td>Tables with borders. This cell a bolded and colorized border because of thead</td>
<td>This cell in this row ALSO has a bolded and colorized border because of thead</td>
<td>This cell in this row is not bolded and colorized</td>
<td>Neither is this one</td>
<td>This table has no borders</td>
<td>This table has no borders</td>
You don't need to worry about colorizing your articles. We have a colorizer that takes care of this for you. If your article already contains colorization then don't worry - the colorizer cleans out all previous colorizing before recolorizing the entire article
<pre lang="cs">int myVar = 0;</pre>
The currently supported languages are:
Other languages can be added on request.
Colorizing works on PRE and CODE tags. If you have a block (or line) of text you don't wish to be coloured, set the lang value as "text".
If you have the same code snippet shown in multiple languages (eg C# and VB versions of the same code) you can wrap multiple PRE blocks inside a <div class="code-samples"> and have the multiple code blocks appear in a tabbed form, similar to MSDN
Just make sure you set the lang attribute correctly
You can paste your article into the editor and modify it using the buttons. Bold, Add Image, Indicate Code in Paragraphs as Variables, Class Names, Properties, Create Lists, Add Link, Remove Automatic Formatting of Original Text Application (like Word), Remove Bad Formatting Insert Table.
There's also Cut, Paste, Redo, and Undo. Beyond these, we wouldn't recommend messing with other icons. Code Project articles have very simple formatting, which is the way we (and more importantly, members) like it.
When you have written your article in another program and wish to paste it into the submission wizard there are a few options you have of how your text is treated. Below is a description of each possible choice and a visual display of what it looks like pasted in the wizard, as well as what you will see in the auto-display window when you paste.
Every article on Code Project can be modified by their author if they are logged in. Simply click on the "Update Article" link just under the title of the article.
This will take you to the article editor where you can make your desired changes. Afterwards, your article will return to the "Articles Needing Approval" queue where members and editors will approve your changes.
If you have trouble with HTML you can send your update to us. Please use the "Get Article’s HTML" from the link in the upper right hand corner of your article, click on this and then save the HTML for your article using the File | Save menu in your browser. Ignore the stuff at the top and bottom of your page - you will see "Article Starts" and "Article Ends" tags in the HTML that point to where the actual text for your article is. Strip out everything above and below these markers and edit the HTML directly. When you are finished please send both updated HTML and zipped sourced code to us at submit[at]codeproject.com. Note: your article and code must be compressed into a .rar archive, or rename your zips to, say, MyArticle.nozip (Our email provider will not accept emails with .exe attachments, or .zips with .exe attachments). Also please remember to include the name of the article and its URL in the email body.
If you only have a very small addition to make, or want to report spelling/grammar or link errors then you can just send these in as plain text.
Alternatively, you can queue your article for editing by using the icon in the top right that looks like a alarm clock: . Please ensure to upload your updated HTML and files as instructed above and include any additional comments the editors need to know.
If you wish to embed a video in your article please email our editors at submit[at]codeproject.com. While articles can have embeded videos using iframes only editors have the ability to implement this currently.
If you wish to submit an article that is purely a video we do support flash or silverlight videos. However, you must have the SWF or FLV file hosted on a server that allows streaming. Simply choose video from change the type of post:
Then and add the URL to the form that appears (shown below).
If you wish to submit an article that is purely a video, but do not have a place to host the SWF or FLV file and have a different format, please email us at submit[at]codeproject.com.
It is OK to use others code as a base as long as you make it totally clear that some/most of the code isn't yours. If you use someone else's code then DO NOT remove their copyright notices. There is a lot of code reuse here, that's the point after all. As far as the articles that are being posted here we expect to see credit where credit's due, in the code and the HTML as appropriate.
If you are submitting a modification, extension or correction to another persons work then we ask that you attempt to contact the original author first and then try to liaise with him/her to produce an update to the original article. This way we can retain continuity with the original article as well as reducing the number of completely new pages that need posting.
We take plagiarism seriously at The Code Project. If you copy someone else's work (whole or even a tiny part) without referencing it, OR you cut and paste large sections and simply post a reference link at the bottom, your post will be removed, and your account and articles may be forfeit.
For further information on how to properly reference material, or an explanation of what plagiarism is, please see our Plagiarism FAQ.
You are more than welcome to submit code that is already published at another site, provided you own the copyright on that article, and provided you have not given the other site exclusive rights to your article.
Certain user-submitted content on the site is subject to moderation. The purpose of moderation is to stop the publication of obviously inappropriate material, plagiarised content or content that is not of sufficient quality to be published at that point.
Moderation is available to members who have contributed enough to the community that the system considers them a good judge of what is and isn't acceptable. If you suddenly find moderation buttons available to you then thank you - you've done a lot for the community and we would now like to give you the opportunity to do even more.
If you have either an author reputation of Gold or higher, an Authority reputation of Gold or higher, an Editor reputation of Gold or higher or an Organiser reputation of Gold or higher, you will have access to the moderation queue. It looks like this:
From there you can hover over the checkbox to get the following dropdown:
The way the moderation works is you have to receive five "Approve" items to be published, or five "Report / Needs help" items to reach a different article status. If five members Approve your article it will become live and available for all to see. If five members either "Report" or mark your article as "Needs help" your article status will become "Closed" and you will receive an email notification indicating who closed the article, why, and what to do:
If you wish to revise and reopen your article based on the feedback from these members then simply go the "Edit article online" in the upper right hand corner:
This will enable you to edit and update your article and will re-open your article for other members to enjoy.
If an author has genuinely tried to provide a decent material, even if they may need some encouraging to improve it, then the item should be approved by moderators.
Pending status means that an article is awaiting approval from the Code Project community. The vast majority of new articles on Code Project need a couple of tiny improvements because they do not sufficiently explain the code within the article. The goal of this is three-fold:
Sometimes articles have great ideas but need a slightly different presentation. If your article is in Closed status, look to your article forum and take the advice of your peers to heart. Generally, your article probably needs to answer one of these questions better:
If you agree with the Code Project users that your submission is more of a Tip than an article you can change it using the article wizard. Simply make sure you are logged in then go to update your article using the icon in the upper right-hand corner:
Then go to the Type of your post and change it on the drop down from Article to Tip as shown below:
Then hit "Publish" and your Tip will now be in the submission queue for Tips.
We have experienced authors who would be willing to help you with your article, to improve it, and help get it approved by the community. If we ask you if you want a Mentor and you say yes, we then submit your article to the Mentor Forum and hopefully one of our Mentors will assign themselves to it, and post helpful suggestions on your article's forum. You can talk discuss with them how to improve the article, and once they feel your article is ready, will make your article available to the community.
Contact us at submit[at]codeproject.com. We're happy to help
Because most new articles require improvements, they receive comments that, once the article is approved, will no longer be relevant. They also receive multiple 1 votes which authors do not like, so we remove both comments and votes. It is permanent. This is also why you cannot reply to some of your initial comments if you were notified by e-mail.
Comments are tied to specific versions in order to allow members to post comments while author's fine tune their article during the composition and approval process.
An example is that you post a new article and it's in a Pending state while members approve it. A few members find fault with it, and you make those corrections, and then the article is approved. The comments related to corrections should not be included in the final published version of the article.
We only have limited staff to deal with thousands upon thousands of articles. We do our best to give them all some lovin', but the sad fact is there are too many. We work as hard as we can. If you can't wait, contact us at submit[at]codeproject.com so we can speed things up.
A tip has the same spirit of a regular article: it is meant primarily to provide a coding solution. However, tips do not require as much detail as an article would to explain a problem and its solution. Articles may be several pages long, but tips might be a couple of paragraphs. Articles are exhaustive, educational pieces meant to teach others (from varying levels of expertise ideally) not just how your code works, but what was learned along the way as well. Tips and Tricks are more straight forward, "how-to" posts than articles. Simply state the problem and its solution. It doesn't necessarily need to have a Download associated - if the sample does not really require it, feel free to leave it.
Then hit "Submit a Tip or Trick." From here on out, everything is identical to submitting an article.
This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)
General News Suggestion Question Bug Answer Joke Rant Admin
Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.