function CIShowToolsSlider() {
var soapEnv = " \
\
\
\
{F55B5D06-1D32-4DCF-8A83-5BC4BA9FDA20} \
\
\
\
\
\
\
\
1 \
\
\
";
jQuery.ajax({
url: "/_vti_bin/lists.asmx",
type: "POST",
dataType: "xml",
data: soapEnv,
complete: CIToolsProcessResult,
contentType: "text/xml; charset=\"utf-8\""
});
};
// process the results from the tools web service CIShowToolsSlider()
function CIToolsProcessResult(xData, status) {
jQuery(xData.responseXML).find("z\\:row").each(function() {
// location of the div the new items should be appended to
var url = jQuery(this).attr("ows_URL");
var title = jQuery(this).attr("ows_Title");
url = url.substring(0, url.indexOf(','));
jQuery("#CIToolsDropDownMenu").append("
Sorry, I don't have time to write a tutorial, but basically it is the same as the other async calls with jquery. It reads a Photo Library, order by date, populate the "ciPhotoOfTheMonth" DIV and call shadowbox to attach the href tags inside of a DIV to shadowbox
For some reason some controls in edit mode throws: save your changes before continuing, click "OK". To continue without saving changes, click "Cancel".
To fix the leave authoring problem in sharepoint you need to add the following tag in the header of your master page:
<meta equiv="X-UA-Compatible" content="IE=EmulateIE7">
Explanation about the X-UA-Compatible http://blogs.msdn.com/ie/archive/2008/06/10/introducing-ie-emulateie7.aspx
xhr.setRequestHeader that you can get from the web services page (see bellow)
in the SharePoint' list you need two columns Title and Description
the browser alert window will return some information that you could remove after testing
after posting the information in the list it will run the processResult function where you can do some fancy user feedback
Html with the fields to be edited by the user
Title:
Description:
In the SharePoint web services description you can extract the value for the xhr.setRequestHeader variable invoking /_vti_bin/lists.asmx?op=UpdateListItems, here is an example:
The technique to remove tags from xml with xslt is very creative. If you have a xml document that is like:
Lorem ipsum dolor sit amet <b> consectetur adipiscing elit </b>. Suspendisse ac ipsum eu orci accumsan dignissim. Fusce fringilla.
The script will store in the variable the items before the "<" and send to recursion the items after the ">".
After a while fighting with forms and content editor web part, I decided to write a jquery script to help with that, basically you replace the form with div and the script will generate a new form when the user submit. You can check out the code here: jquery sharepoint form
For some reason SharePoint translate your FileRef links in XSLT when you use the data view web part, content query web part, or any other XSL in SharePoint. It translates to the library link. To fix it, you have to use the xsl:attribute. Example:
There is a small bug in IE that makes $.text() return garbage text at end, in case you have a bug that you cannot nail down, debug the problem using:
alert(encodeURIComponent($.text(...)));
that will show any hidden character.
More information about encodeURIComponent: http://xkr.us/articles/javascript/encode-compare/