cancel
Showing results for 
Search instead for 
Did you mean: 

Use xsd

naveenkumar
Champ in-the-making
Champ in-the-making
Is it possible to use schema to create content outside of the web projects??
How to display custom meta data in web client while creating content inside web projects??
8 REPLIES 8

arielb
Champ in-the-making
Champ in-the-making
Is it possible to use schema to create content outside of the web projects??

not currently.

How to display custom meta data in web client while creating content inside web projects??

i don't understand the question.  could you elaborate please?

naveenkumar
Champ in-the-making
Champ in-the-making
I want to use my custom content types while creating a content inside the web projects. i created my content model and the content types are appeared in the front end, then i selected my content type to create a content inside web projects.when i click view, not able to see my custom properties. By default it points to avmcontent.

please help me…..

kvc
Champ in-the-making
Champ in-the-making
Currently, content models in the AVM (a web project) are defined via an XSD and content model in a traditional space via the traditional content model (which defines a single content type for all AVM assets).  They are not shareable in either direction.

This will change post our 2.1 release (target June).  The traditional content model for spaces is really a metamodel that should be defined via an XSD, with specific structured content types - whether used in a traditional space or web project - defined by an additional XSD via an include.  We are still working out the details of merging these two content model definitions.  In the meantime, you can use an XSD to create the same content model you would in a traditional space, register as a web form, and when you create a new asset like a Word doc access the web form, use the file browser to upload and create a reference to the underlying Word doc, and use the form for the metadata that will live as an XML asset.  A bit less elegant (in that that XML metadata should be bound to the asset via attributes as opposed to living as a separate asset, though this has advantages in that it is exposed via CIFS, which will also continue being supported in the future using CIFS proc files to expose asset attributes as XML files in a virtual manner). 

Let me know if more questions.

Kevin

spatil
Champ in-the-making
Champ in-the-making
Is it possible to use web forms to edit XML files that are not part of any web projects. These are XML files located in a regular ECM space.

The intention is to have better editing capability for XML files, than just the text-like editor provided for inline editing of XML files.

So an XSD file would be associated with the XML file and the XForms will be used to capture and persist instance data into the XML file (initial data population and editing too), along with validation based on the XSD file.

kbonnet
Champ in-the-making
Champ in-the-making
Is it possible to use web forms to edit XML files that are not part of any web projects. These are XML files located in a regular ECM space.

The intention is to have better editing capability for XML files, than just the text-like editor provided for inline editing of XML files.

So an XSD file would be associated with the XML file and the XForms will be used to capture and persist instance data into the XML file (initial data population and editing too), along with validation based on the XSD file.

Hi Spatil, better late then never Smiley Happy

I had this same requirement. With the release of version 2.9B this has become possible. You can now create all content based on a form. If this content is not part of a web project, there is no built-in way yet to render the resulting XML into a webpage. To overcome this, i have created a script that modifies the XML to call an XSLT stylesheet. This script is called from a content rule on the space i want the content in.

Does this answer your wishes too?

Koen

tsoifan
Champ in-the-making
Champ in-the-making
Hi Koen (and all),

This is timely for me. I've just created a similar script, and I'm having trouble with the relative address to the XSL file. Where are you locating yours, and what to you use for the reference?

Keith

kbonnet
Champ in-the-making
Champ in-the-making
Hi Keith,

having trouble with the relative address to the XSL file. Where are you locating yours, and what to you use for the reference?

I have used the "view in browser" link from the details page of the XSL file. My scripts is this one below. I'm just replacing the existing processing instruction by two new ones. In the topic i linked to in my previous post is the suggestion to use E4X-script, although the poster there also stated he used this kind of text parsing/replacement too.

Does this help you?

xmltext = document.content;
pi = '<?xml version="1.0"?><?xml-stylesheet type="text/xsl" href="/alfresco/d/d/workspace/SpacesStore/7e9f86e1-e6e7-11dc-b181-65bd8e557e77/Stylesheet" ?>';
document.content = xmltext.replace('<?xml version="1.0" encoding="UTF-8"?>',pi);

Koen

tsoifan
Champ in-the-making
Champ in-the-making
Hi Koen,
Does this help you?

href="/alfresco/d/d/workspace/SpacesStore/7e9f86e1-e6e7-11dc-b181-65bd8e557e77/Stylesheet"
Yes, a look at that href is exactly what I needed. I didn't originally think of placing the stylesheet in the managed content.
One extra thing I have my script doing; deleting any previous stylesheet reference, so the script doesn't add an extra one each time the form is edited.

Thanks,

Keith