Sulu smart content filter feature (Drupal's exposed filter like) - sulu

I'm working on a sulu project (I think it is currently on 1.3) and using its smart content feature to display teaser lists.
What I would like to achieve now is to make these lists user filterable [edit: website user, not content manager] e.g. by tag, a bit like the Drupal Views' exposed filter feature. Did I miss something or does it simply not exist in the Sulu world?
I don't need any advanced search backend as in the SuluSearchBundle, a way for the user to edit the filtered tags would be completely sufficient for the moment.
Thanks in advance and best regards
Sören

That's a built-in feature in Sulu, the content manager can decide how to filter the smart content, based on e.g. tags & categories. When you click on the configuration button for the smart content you see a overlay like this:
On the autocomplete for "Filter by tags" you can enter by which tag the smart content should be filtered.
UPDATE 2017-06-14:
You can also let the user filter for tags, that's what the tags_parameter parameter in the template configuration is for:
<property name="smartcontent" type="smart_content">
<meta>
<title lang="de">Smart-Content</title>
<title lang="en">Smart-Content</title>
</meta>
<params>
<param name="tags_parameter" value="tags"/>
<param name="properties" type="collection">
<param name="title" value="title"/>
<param name="article" value="article"/>
<param name="ext_title" value="excerpt.title"/>
<param name="ext_tags" value="excerpt.tags"/>
<param name="ext_images" value="excerpt.images"/>
</param>
</params>
</property>
Now you can append something like ?tags=tag1,tag2to the URL and the content will be further filtered.

Related

Add aria-hidden to Title element

I am trying to make a business critical SAPUI5 application more accessible using screen readers by adding ARIA labels and landmarks. One issue is that some SAPUI5 elements such as sap.m.Title's without text have been used (abused) for layout purposes. I would like to add the aria-hidden attribute or a SAPUI5 analogue to these Title elements. But I can't figure out how to do this. I would like to change
<Title text="" class="title" />
into
<Title aria-hidden="true" text="" class="title" />
But setting aria-hidden on the Title like this seems to be invalid. How would I go about setting a standard HTML attribute on a SAPUI5 control?
Thank you in advance for your help!
Joshua

How to change the group position of an Add-in inserted into a default office tab?

I have created an Office Add-In for Word, and the icon is placed into the Insert tab, but by default it is in the very last position on the ribbon. I want my group to be placed in the first position of the tab, before Pages (this appears to be the first group by default). Is there something I can add into the manifest XML file to place the group at the start of the tab?
My manifest file currently looks something like this:
...
<ExtensionPoint xsi:type="PrimaryCommandSurface">
<OfficeTab id="TabInsert">
<Group id="MyCompany.MainGroup">
<Label resid="MyCompany.MainGroup.Label" />
<Icon>
...
</Icon>
<Control xsi:type="Button" id="MyCompany.ActionButton">
<Label resid="MyCompany.ActionButton.Label" />
...
</Control>
</Group>
</OfficeTab>
</ExtensionPoint>
...
I would imagine that if this is possible, there should be something I can add underneath the Group element, but I don't see anything relevant in the documentation. On the other hand, absence from the documentation doesn't mean it doesn't exist, since the Icon element is not listed there either, and without it my Add-In doesn't load.
The other element I can imagine a suitable option would exist is on the ExtensionPoint (documentation), but I don't see anything suitable there either.
This is not possible. The add-in buttons would always come after the default office ribbon controls. The only way where you can insert them at the beginning of the line would be to create a custom tab.

How Can to Edit the Blog Layout in Orchard Cms?

I want to change the blog layout.I want to order this in title then publish date,picture and then description.but I don't know how to do this.can you help me plaese?
Please read up on some Orchard documentation about placement, alternates and shapetracing.
The simplest thing you can do, for just changing the order of rendering, is changing the placement.info of your theme to something like this:
<Match ContentType="Blog">
<Place Parts_Title="Content:1" />
<Place Parts_MetaData="Content:2" />
<Place Fields_MediaLibraryPicker="Content:3" />
<Place Parts_Blogs_Blog_Description="Content:4" />
</Match>
If you want to have full control over the rendering of the layout you can create an alternate. Use the shape tracer to find the correct alternate (probably something like Content-Blog.cshtml), and tweak your stuff in there.

Embedding MP4 videos on my website

Is there a way to display MP4 videos in its original size. It looks like we have to provide Width and Height and if we don't it will default to some value other than it's original size.
<OBJECT CLASSID="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
CODEBASE="http://www.apple.com/qtactivex/qtplugin.cab" WIDTH="160" HEIGHT="136" >
<PARAM NAME="src" VALUE="videofilename_mp4.mov" >
<PARAM NAME="autoplay" VALUE="true" >
<EMBED SRC="videofilename_mp4.mov" TYPE="image/x-macpaint"
PLUGINSPAGE="http://www.apple.com/quicktime/download" WIDTH="160" HEIGHT="136" AUTOPLAY="true"></EMBED>
</OBJECT>
If I recall correctly you will have to read it from the metadata. I currently use the free version of Flowplayer.
You can pass it an option "scale:fit" http://flowplayer.org/documentation/api/clip.html
This tells the flash Flowplayer to read the file metadata and scale the video to fit inside the player container with the proper aspect ratio.
I know you probably don't want a flash solution but this is an option.

Issuu-Not working in Safari

I have a website that embeds issuu documents. Now it seems as the expanding and browsing through the document works in Firefox but not in Safari. You can try it out here: http://uniteich.at/service/agent Nothing happens in Safari if I click on the document.
Here is the html-code snippet where I bind in the issuu-code:
<div class="issuu">
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" style="width:320px;height:240px" id="add9c3c4-afc6-970e-36fb-28ae7e20a616" >
<param name="movie" value="http://static.issuu.com/webembed/viewers/style1/v2/IssuuReader.swf?mode=mini&embedBackground=%23ffffff&backgroundColor=%23222222&documentId=120229092309-6b8da62cea0f428f95a491abc5302843" />
<param name="allowfullscreen" value="true"/>
<param name="menu" value="false"/>
<param name="wmode" value="transparent"/><embed src="http://static.issuu.com/webembed/viewers/style1/v2/IssuuReader.swf" type="application/x-shockwave-flash" allowfullscreen="true" menu="false" wmode="transparent" style="width:320px;height:240px" flashvars="mode=mini&embedBackground=%23ffffff&backgroundColor=%23222222&shareMenuEnabled=false&documentId=<?php print($fields['field_issuu_id_value']->content);?>" /></object>
</div>
I would be very thankful for help,
thanks enne
This is Safari's responsibility for not rendering Flash content.
The embed code you're using is Issuu's old embed code that only includes the Flash embeds. If you use their new embed like this
<div data-configid="6943700/11183544" style="width:525px; height:376px;" class="issuuembed"></div><script type="text/javascript" src="//e.issuu.com/embed.js" async="true"></script>
the embed will also render in browsers that don't support Flash (e.g. on the iPad etc).
You can get the new embed code from your document's page http://issuu.com/uniteich.at/docs/agent_3_final_web_0#embed or from the Publisher Tools (open menu -> "Embed").