The SharePoint survey list, by default, only supports simple text surveys and does not meet most of the requirements, and it takes a lot of work to customize a pretty little survey. In order to make most of the developers know little about the SharePoint administrator or advanced users can easily produce an illustrated survey, close-up of this article.
Step one: Create a general survey list.
Step Two: Open the survey in SharePoint Designer and upload a picture for backup.
Step three: Create a new HTML page in the middle of SharePoint Designer to copy the display style of the problem
Step Fourth: Copy the generated code and paste it into the middle of the survey question (note that you include the table tag)
Preview:
Step Fifth: Copy the following JavaScript code to each file
document.getElementsByTagName (' Table '). Item (0). outerhtml
=
document.getElementsByTagName (' Table '). Item (0). Outerhtml.replace (/</g, ' < '). Replace (/>/g, ' > ');
Tip: If you don't know where to put the code, you're looking for a snippet of code in the file, which has a JavaScript code to just put your code down.
Preview results:
Description
The function of JavaScript code here is to turn the characters that are escaped by SharePoint back again so that HTML formats like pictures can be displayed properly.
Updated [2009-11-02]:
For Mike Sharp ' s idea here:http://social.technet.microsoft.com/forums/en-us/sharepointcustomization/thread/ 8b97bc31-f72d-4104-bd40-d8d72a8f7fbf
There should be a potential for XSS, and narrow the scope of what gets un-escaped should reduce the risks:
For Dispform, NewForm and editform pages. Using
document.getElementById (' Onetidlistform '). rows[0].cells[0].innerhtml = document.getElementById (' OnetIDListForm ') . Rows[0].cells[0].innerhtml.replace (/</g, ' < '). Replace (/>/g, ' > ');
For the Summary page doesn ' t have the same onetidlistform cell, using the ID of the Web Part Zone TD Cell:
document.getElementById (' msozonecell_webpartwpq2 '). InnerHTML = document.getElementById (' msozonecell_webpartwpq2 ') ). Innerhtml.replace (/</g, ' < '). Replace (/>/g, ' > ');