Im using this like code on my website and W3C Dont Like It Can someone please give me the right code i should use to pass so i know where im going wrong please see code at http://www.justvibe.co.uk/ as i cant seam to post it up.
Thanks
Dan
*ERRORS***
Validation Output: 7 Errors
Line 37, Column 105: required attribute "type" not specified…ect.facebook.net/en_US/all.js#xfbml=1">
The attribute given above is required for an element that you've used, but you have omitted it. For instance, in most HTML and XHTML document types the "type" attribute is required on the "script" element and the "alt" attribute is required for the "img" element.
Typical values for type are type="text/css" for and type="text/javascript" for .
Line 37, Column 129: there is no attribute "href"…ll.js#xfbml=1">
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the element to incorporate flash media in a Web page, see the FAQ item on valid flash.
Line 37, Column 163: there is no attribute "send"…ref="http://www.justvibe.co.uk/" send="true" width="450" show_faces="true" fon…
✉
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the element to incorporate flash media in a Web page, see the FAQ item on valid flash.
Line 37, Column 176: there is no attribute "width"…ww.justvibe.co.uk/" send="true" width="450" show_faces="true" font="arial">
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the element to incorporate flash media in a Web page, see the FAQ item on valid flash.
Line 37, Column 193: there is no attribute "show_faces"…tvibe.co.uk/" send="true" width="450" show_faces="true" font="arial">
✉
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the element to incorporate flash media in a Web page, see the FAQ item on valid flash.
Line 37, Column 205: there is no attribute "font"…tvibe.co.uk/" send="true" width="450" show_faces="true" font="arial">
✉
You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).
This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.
How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the element to incorporate flash media in a Web page, see the FAQ item on valid flash.
Line 37, Column 212: element "fb:like" undefined…tvibe.co.uk/" send="true" width="450" show_faces="true" font="arial">
✉
You have used the element named above in your document, but the document type you are using does not define an element of that name. This error is often caused by:
•incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Frameset" document type to get the "" element),
•by using vendor proprietary extensions such as "" or "" (this is usually fixed by using CSS to achieve the desired effect instead).
•by using upper-case tags in XHTML (in XHTML attributes and elements must be all lower-case).
You should add the appropriate namespace attribute for XFBML to the html tag:
xmlns:fb="http://www.facebook.com/2008/fbml"
This is mandatory for IE to work properly with Facebook social plugins.
And if you want to use Open Graph:
xmlns:og="http://opengraph.org/schema/"
The W3C validator will still show errors as it doesn't take the additional namespaces into account.
If you want to pass it that way, you need to output the FBML via JavaScript and wrap things in CDATA:
<script language="javascript" type="text/javascript">
//<![CDATA[
document.write('<fb:like href="http://www.yourdomain.com" layout="button_count" show_faces="false" width="450" action="like" font="arial" colorscheme="light"></fb:like>');
//]]>
</script>
You are using the HTML5 version of the like button with a non-HTML5 doctype. Use the XFBML version with the XML namespace added to your HTML tag instead, or convert your page to HTML5. You'll also need to add type="text/javascript" to the <script> tag.
Related
The document body is hardcoded and then inserted into a template document with contains cover, summary, headers and styles. Heading styles are numbered 1, 1.1, 1.2, and so on. But to insert a heading just with 'Heading [n]' style does not work, numbering is lost. I think this happens because numbering is set through a multilevel list with headings attached.
Question: is it possible to use a document as a template without coding any formatting, or it is inevitable to deal with list styles in the code?
Yes, you can use a document as a template without any formatting. Please note that when you copy nodes from one document to another, this option specifies how formatting is resolved when both documents have a style with the same name, but different formatting.
The formatting is resolved as follows:
Built-in styles are matched using their locale independent style
identifier. User defined styles are matched using case-sensitive
style name.
If a matching style is not found in the destination document, the
style (and all styles referenced by it) are copied into the
destination document and the imported nodes are updated to reference
the new style.
If a matching style already exists in the destination document, what
happens depends on the importFormatMode parameter passed to
Document.ImportNode as described below.
When using the UseDestinationStyles option, if a matching style already exists in the destination document, the style is not copied and the imported nodes are updated to reference the existing style.
So, in your case, I suggest you please use UseDestinationStyles option while inserting one document into another.
I work with Aspose as Developer Evangelist.
In my home page I have the following snippet that fetches all blog posts:
var docs = CurrentPage.Children.Where("Visible")
What I don't understand is that Visible is controlled by a property in the document named umbracoNaviHide. Setting it to true on the document excludes the page from the list above.
How is umbracoNaviHide translated to Visible? I have no macros or XSLT (none actually) that is doing anything funny...
umbracoNaviHide is one of umbraco's internal property implementations.
We used to have to check the property explicitly in xslt but nowadays it is used as you are using it here.
Here is a more complete explanation from the Umbraco wiki
The "umbracoNaviHide" is an Umbraco convention for marking nodes which
should not show up in a navigational context. It is normally added (or
inherited) on every Document Type with a Data Type of "True/false".
NOTE: This property is not added by default on new installations,
meaning you need to add it manually
There are a number of other useful properties that everybody should know about:
umbracoSitemapHide
umbracoUrlAlias
umbracoUrlName
umbracoInternalRedirectId
umbracoRedirect
We always insert these properties on a master page doctype so that all other doc types that represent data on web page content nodes inherit them
Wing
I'm having some trouble loading the document (see link http://pastebin.com/FE3nDX9h) in pugixml.
I'm getting an error code of 16: No document element found which indicates that the XML file is invalid or empty which I think is neither.
I am using the default parsing method. Is there something I am missing?
edit: as requested heres some source code http://pastebin.com/USUjLC4q you will need to edit the paths.
You need xml_document::load_file but xml_document::load.
From pugi documentation:
There is also a simple helper function, xml_document::load, for cases when you want to load the XML document from null-terminated character string.
So, load's argument has to be xml by itself, not file name.
The XML below represents a FIX message. This message has a variable number of fields (numbered using the id tag), each containing differing attributes. So I would like to parse this XML and with my additional coding abilities output a C++ message object which includes all the attribute information per field.
First question would be- is there a boost library which I can use to do this? My second question would be what is the interface between what the XML parser can provide and where I have to write code to create the objects. So for example, in the XML on line 8 there is a <delta/> tag and this is an attribute of the object. So for field 52 (line 8) the attribute would be a Delta sub type object but for line 9 the attribute would be a Copy subtype object. I would like to store these subtypes in an std::unordered_map with the field ID being the key.
I guess another way of wording this is- what "end result" will the XML parser give me to help build the objects the way I want them?
You should probably use one of the many commonly-used xml parsers, Xerces and TinyXML are two possibilities. There are more. Google is your friend.
You want to run in SAX mode rather than DOM mode (the documentation for the parser you choose will explain). That means the parser will call code you supply for each element and attribute it parses rather than building an arbitrary structure in memory that doesn't match your domain-specific needs.
There's a document I'm displaying in a web browser ActiveX control hosted in a C++ app. This document has a META tag that specifies incorrect charset, so the output is funny. I know the correct encoding and want to change it programmatically to fix that. But whatever I try, the encoding remains unchanged.
I alredy tried, in various combinations and flavors:
IHTMLDocument2::put_Charset (after the document finished loading);
changing the "charset" property of the "META" tag (using IHTMLMetaElement);
deleting the "META" tag altogether (by setting its "outerHTML" to empty string);
refreshing the control.
The control demonstrates remarkable persistence in preserving the incorrect encoding. What are my other options? I can't manipulate the source of the document being loaded.
try to put the designMode property "On".
According to this, it should work if you call IWebBrowser->Refresh() after calling IHTMLDocument2->put_charset().
Here's what eventually worked:
In the handler of the "NavigateComplete2" browser event,
the charset is modified using the charset property,
then the META tag is thrown away by setting its outerHTML to empty string,
and then the control is refreshed.
Modifying the order of these actions, or omitting a step, will render the entire operation void. MSHTML is picky.