cancel
Showing results for 
Search instead for 
Did you mean: 

WCM Functionality

tqu
Champ in-the-making
Champ in-the-making
Hello everyone,

we are supposed to create some intranet functionality with the Alfresco WCM for a client of ours. Regarding this project I’ve got some questions:

1. Is there any other way to access repository files in a web project other than copying those files to the web project? As far as I know it is at least possible (in release 2.1.0) to create a rule to automate this process. The disadvantages of this are that I have to keep the files in a specific folder (if I don’t want to create the rule for a dozen different folder)
and the destination for the files is always the same. All things considered I’m quite inflexible. I’m just wondering if a better integration of repository files into the WCM is planned in the near future?

2. A web project is, as far as I know, still not searchable. http://issues.alfresco.com/browse/WCM-411 tells me that this functionality was implemented in version 2.1 but like Joseph I can’t get it to work. In other words Alfresco won’t find any files in a web project. Am I just missing something?

3. Recursive elements in XML schema don’t work http://issues.alfresco.com/browse/WCM-435. I think this is quite a pressing issue. If I, for example, want to create a dynamic navigation, I would have to predefine the depth of the navigation. Currently it is not possible to create a navigation structure with an arbitrary depth. And there are other use cases to think of. Now the question is: is it planned to provide this functionality in near future?
4. When I create content via a web form an xml and an html file is generated. When I import those files into another Alfresco and try to edit them it won’t open the forms editor. Does this mean that I have create all the content on the final WCM in order to manage it via web forms?

5. Although the WYSIWYG editor in release 2.1.0 is more sophisticated it still provides relatively little functionality for end users (compared to WYSIWYG editors in other WCMS). Is it planned to extend the functionality of the WYSIWYG editor in near future?
Pure HTML files in the web project won’t open with the WYSIWG editor. Is such functionality planned?

I would appreciate any tips for workarounds or any statements regarding the roadmap for Alfresco’s WCM.

Regards,
Torben
10 REPLIES 10

randomman
Champ in-the-making
Champ in-the-making
On the subject of #1, I'm currently experimenting with accessing repository files via web services.

I've created some test categories and categorised some repository files. I've then created a web service (based on the existing categorysearch web script) that'll extract the documents i want.

I guess you could use this as the basis for a whole site with all your content in the repo and categories effectively acting as navigation structure. No idea whether or not this is a good idea as no-one ever seems to answer any of my questions on the subject.  :roll:  I'm still evaluating it so I've got no real thoughts either way yet, just seeing what it can do.

My current problem is that you appear to have to log in to access files when linking to them like this:
/alfresco/service/api/node/content/workspace/SpacesStore/[storeid]/[filename]
..which is a bit useless for random web users. I'm sure I'll think of something.  :wink:

Regarding #4, is that because you haven't set up the equivalent web form in the other Alfresco and attached it to the new web project?

This forum post  might shed some light on #5.

Hope this helps!

mark_smithson
Champ in-the-making
Champ in-the-making
On #2

You need to configure an XmlMetaDataExtractor to extract the xml properties so that it can be indexed for search.

However it seems that the search in the web client does not include the avm stores in its search - at least from my experience. Finding out how to get it to include a web project in the search is on my TODO list.

You can search by creating a WebScript and setting the defaultStore as I descibed here:

http://forums.alfresco.com/viewtopic.php?t=7809

Also I think that only the staging sandbox for a web project is indexed, not the sandboxes for any users (which kind of makes sense, although it would be nice if a user performing a search could get results in their own sandboxes)

tqu
Champ in-the-making
Champ in-the-making
Hey Random Man,

thanks for you idea, I'll take this into consideration. But as you say: neither is it easy to come up with a new idea nor is it always clever to implement a solution of your own, because you never really know if it will still work in future releases of Alfresco. And reimplementing something over and over again is just not feasible.
Regarding #4: I do have the correct web form attached to my project. It doesn't even work when I create a new web project on the same Alfresco and export / import the data from one project to the other.
Regarding #5: I've already seen that posting. Thank you. That's why I wrote "more sophisticated"  :wink:. It is getting better, I admit, but I still miss functionality like "creating tables", "insert special characters" or "editing the HTML source code". In my opinion it is quite difficult to create a proper structure for web content without tables.

And Mark,
I will try you solution. Thank you for that. Although I have to say that it would be a much more sophisticated solution if it was already implemented in Alfresco itself. So we can just hope there will be a proper solution to this problem soon  :wink:.

Thanks again

mark_smithson
Champ in-the-making
Champ in-the-making
On #5 - I have not looked into it, but I remember seeing somewhere that you can control the toolbar icons on the tinyMCE editor that is used for WYSIWG.

tinyMCE is quite comprehensive.

kevinr
Star Contributor
Star Contributor
2. A web project is, as far as I know, still not searchable. http://issues.alfresco.com/browse/WCM-411 tells me that this functionality was implemented in version 2.1 but like Joseph I can’t get it to work. In other words Alfresco won’t find any files in a web project. Am I just missing something?

Files in web projects are now indexed, there is no UI however built in yet for this. The various search APIs can be used, this includes the Template API and the JavaScipt APIs. So you can build custom views based on templates (or WebScripts) and write JavaScript rules etc. that perform searching on WCM stores.

Thanks,

Kevin

tqu
Champ in-the-making
Champ in-the-making
Thanks Kevin,
I hope this functionality will be integrated into Alfresco in the near future. Until then I'll have to help myself the way you described.

…after some more research I found out a little bit more about the WYSIWYG editor in release 2.1.0.
Plugins like tables are supposed to be available in release 2.1.0E: http://issues.alfresco.com/browse/WCM-598
I did find a way to even extend the editor further than described in the other link Random Man posted. The trick is to extend the web-client-config-wcm.xml. The default buttons available for TinyMCE are listed here:
http://wiki.moxiecode.com/index.php/TinyMCE:Control_reference
This way it is at least possible to "edit html code", "superscript", "subscript", "insert horzontal lines", etc.

Regards,
Torben

kvc
Champ in-the-making
Champ in-the-making
For those working with any nightly build or checking out the latest source from svn, here's the current state of textarea config options from web-client-config.xml (to be available in 2.1.0E):


           <widget xforms-type="xf:textarea"
                   appearance="minimal"
                   javascript-class-name="alfresco.xforms.PlainTextEditor"/>
           <widget xforms-type="xf:textarea"
                   javascript-class-name="alfresco.xforms.RichTextEditor">
             <param name="theme_advanced_buttons1">bold,italic,underline,separator,forecolor,backcolor,separator,link,unlink,image</param>
           </widget>
           <widget xforms-type="xf:textarea"
                   appearance="full"
                   javascript-class-name="alfresco.xforms.RichTextEditor">
             <param name="theme_advanced_buttons1">bold,italic,underline,strikethrough,separator,fontselect,fontsizeselect</param>
             <param name="theme_advanced_buttons2">link,unlink,image,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,bullist,numlist,separator,undo,redo,separator,forecolor,backcolor</param>
             <param name="height">400</param>
           </widget>
           <widget xforms-type="xf:textarea"
                   appearance="custom"
                   javascript-class-name="alfresco.xforms.RichTextEditor">
             <param name="theme_advanced_buttons1">bold,italic,underline,strikethrough,separator,fontselect,fontsizeselect</param>
             <param name="theme_advanced_buttons2">link,unlink,image,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,bullist,numlist,separator,undo,redo,separator,forecolor,backcolor</param>
             <param name="height">600</param>
             <param name="mode">exact</param>
             <param name="force_p_newlines">true</param>
             <param name="apply_source_formatting">true</param>
             <param name="plugins">table</param>
             <param name="theme_advanced_buttons3">tablecontrols</param>
           </widget>


With 2.1.0, we've enabled plug-ins for TinyMCE (there are a host of them) and out-of-the-box add a default appearance type called 'custom' that loads in the table plug-in and presents a list of table controls to the end-user.  Any TinyMCE plug-ins with associated controls can be added in a similar manner.

We'll be updating documentation on our wiki related to web form customization with 2.1.0E.  In the meantime, if you'd like to experiment with these new options, I recommend downloading the latest nightly build.


Kevin

tqu
Champ in-the-making
Champ in-the-making
Thanks Kevin,

I tried the new build and the tables plugin in the editor works just fine. Very nice. Unfortunately I wasn't able to load other plugins.
I downloaded the TinyMCE plugins and copied them into the tiny_mce/plugins folder. Then I changed the web-client-config-wcm.xml into, for example:

<param name="force_p_newlines">true</param>
<param name="apply_source_formatting">true</param>
<param name="plugins">layer</param>
<param name="theme_advanced_buttons3">moveforward,movebackward,absolute,insertlayer</param>

Unfortunately that didn't work. Am I missing something? But definitely: it is heading the right direction.

kvc
Champ in-the-making
Champ in-the-making
Hmmm … will look into and get back to you.

Kevin