First of, I've searched far and wide about this issue, and it should be working.
I want to add a picture to my Welcome.aml with Sandcastle.
Inside the Welcome.aml:
<section>
<title>Short process description</title>
<content>
<para>
A short description
</para>
<para>
<medialinkInLine>
<image xlink:href="ShortProcess"/>
</medialinkInLine>
</para>
</content>
</section>
I've added the image to my media folder and uses the Image ID in xlink:href.
But nothing appears.
Log files mention it here:
Copying images and creating the media map file...
C:\blaablaaa\blaaaa\Doc\Doc\Media\ShortProcess.jpg -> C:\blaablaaa\blaaaa\Doc\Doc\Help\Working\Media\ShortProcess.jpg
Generating conceptual topic files
Anyone got an idea?
I did some documentations for my own projects and tumbled acros a very important fact
[cite]... Also, make sure the href ID on the image element matches the
ImageId property on the image file in the project explorer window. If
you use the Entity References window to list the images in the
project, you can drag and drop them from there into the documents and
they will be added with the proper element name and ID[/cite]
citation taken from Sandcastle discussion forum
Usage in my latest demo project
For further details you may have a look at mediaLink description at sandcastle itself.
Apperantly medialinkInLine didn't work for me. Even though it worked for a co-worker.
<section>
<title>Short process for BladeSet</title>
<content>
<para>
A rough description of the BladeSet application.
</para>
<mediaLink>
<image xlink:href="Short process for BladeSet"/>
</mediaLink>
</content>
</section>
Related
Unfortunately there's no details/summary element in the default CKEditor configuration of TYPO3 and I'm looking for a way to add it.
What I've been trying to do:
I searched and found a widget on https://ckeditor.com/cke4/addon/detail , but it's repository on GitHub has been archived and the widget does not work as expected. It requires 'api,widget' and this generates a JavaScript error:
[CKEDITOR.resourceManager.load] Resource name "api" was not found at "/typo3/sysext/rte_ckeditor/Resources/Public/JavaScript/Contrib/plugins/api/plugin.js?t=K24B-4e13cc129f".
When removing this requirement for "api", there's an error regarding line 72
CKEDITOR.api.parser.add(item, el);.
Then I found a similar widget at GitHub , which looks like an older version of the former without requirement for "api".
It already looks quite good, but is still a bit buggy: the HTML structure is changed when saving and the summary is duplicated. When switching to the source code, the HTML structure specified in the template ...
<details><summary>Summary</summary><div class="details-content"></div></details>
… get's partially lost.
I'm not sure if the widgets are buggy or if the editor is limited by the integration into TYPO3 and I was also not able to combine the two in a way that would lead to a working solution.
Update (Jul 22):
I successfully modified the Creating a Simple CKEditor Widget (Part 1) example to create
a widget with the following HTML structure:
<div class="expander">
<p class="expander-title">Title</p>
<div class="expander-content"><p>Content...</p></div>
</div>
With the help of a small JavaScript snippet and some CSS it now behaves almost like a details-summary element, but is not quite as good in terms of SEO and accessibility.
If I replace the elements <div class="expander"> and <p class="expander-title"> with <details> and <summary> in the widget, it unfortunately doesn't work properly anymore and changes the structure when saving. For some reason the RTE treats them differently.
I have already manually added the following to the RTE configuration:
processing:
allowTags:
- details
- summary
allowTagsOutside:
- details
- summary
Not even sure I labeled this correctly, I am in the process of converting a site to Umbraco, and there are sections of the site that needs to be edited using the CMS tools in the back end, basically it is a grid with pictures and description text
Here is a sample of the HTML
<div class="hi-icon-effect-1 hi-icon-effect-1a">
<a class="hi-icon">
<img class="img-responsive " id="ImgSales" src="../../Images/sales_icon_circle_grey.png" alt="">
</a>
<p style="padding-left:5px;" id="lblSales" class="">Sales</p>
</div>
What I would like to be able to do is go to the content section of the admin and edit the list of items and configure the image and text for each item.
http://www2.strikemedia.co.za/
If you view the above link and scroll down there will be a grid of items (services) and it is this list that I want to be able to generate.
I am comfortable with all the technologies used in Umbraco, I just do not know the system well enough to do these kinds of modifications, can someone please assist or point me to the resources that will help me build this.
Thanks
You should take a look at the Archetype package: https://our.umbraco.org/projects/backoffice-extensions/archetype/
As far as I understand your question you are looking for a way to add X amount of similar items to the contents of a page - for this, Archetype is probably perfect :-)
Once you have your list of items added inside Umbraco, look here: https://github.com/kgiszewski/ArchetypeManual/blob/master/03%20-%20Template%20Usage.md
Use case #1 in this example will allow you to iterate through items and output it with whatever "template" you want (aka the HTML sample you provided).
i create a Document(PDF) and get the Content from the Umbraco nodes.
But there's a problem by displaying the images. How can i display or get the images from the Media libary of Umbraco? Is there a way, offered from Umbraco to get the Image(s)?
Thanks a lot.
If I understand your query correctly, you a pretty much there.
You should simply be able to get the umbracoFile path (just like you are for the PDF file) and simply declare it as the img src!
With Razor...
<umbraco:Macro runat="server" language="cshtml">
<img src='#Model.MediaById(#Model.imgProperty).umbracoFile' alt="" />
</umbraco:Macro>
The Ajax accordion on my page isn't functioning at all. It displays fine on the page, but I can't seem to expand/collapse the panes when I click on their Headers.
Here's my code (just the HTML portion as I'm not aware of any code behind that is needed):
<aj:Accordion runat="server" ID="acMain" SelectedIndex="0"
FadeTransitions="true"
TransitionDuration="400"
FramesPerSecond="40" RequireOpenedPane="false" TabIndex="0"
SuppressHeaderPostbacks="true" HeaderCssClass="acHeader"
HeaderSelectedCssClass="acHeaderSelected">
<Panes>
<aj:AccordionPane runat="server" ID="Panel1">
<Header>
...
</Header>
<Content>
...
</Content>
</aj:AccordionPane>
<aj:AccordionPane runat="server" ID="Panel2">
<Header>
...
</Header>
<Content>
...
</Content>
</aj:AccordionPane>
</Panes>
</aj:Accordion>
I've checked the official page for the Accordion as well as a number of blogs on the subject (all of which seem to be a copy of the official page with the author's own wording) and according to all of this, I can't see that I've done anything wrong or missed anything out.
Matter of fact, I've checked an Accordion my boss made a while back and my code's basically the same as his (only panel content is different) and he has no code-behind either, so I'm really lost here.
Any help will be greatly appreciated
EDIT
After adapting my code according to a sample on asp.net, I've managed to collapse the first pane (SelectedIndex 0), but the other one won't expand :/
So I copied the accordion code from the asp.net how to page and put my content into the panes, still had no effect.
As it turns out, there was a rogue </div> tag in my content that was wrecking the accordion so I recommend that anyone having any similar problems checks their content very thoroughly.
Also, it's worth noting here that as this particular sample worked for me and because I'm telling you to use it if you're having trouble, it's author did leave an incorrectly closed </p> tag that might cause problems with your accordion during testing, so watch out for that.
This feels like a newbie question but:
I am trying to create a new page from the drop-down display menu so that I can supply a background color to the page (so end user doesn't have to go into the html and add a div). I tried adding a new (empty) div to the template but it's not working. Is this even possible?
Here is my code (my div is called "s_holder"):
<metal:field use-macro="python:here.widget('text', mode='view')">
Body text
</metal:field>
<div metal:use-macro="here/document_relateditems/macros/relatedItems">
show related items if they exist
</div>
<div tal:replace="structure provider:plone.belowcontentbody" />
</tal:main-macro>
</metal:main>
<div id="s_holder"></div><!--end s holder-->
</body>
</html>
For the part of creating the new display view: as #Auspex said, you should put the div inside the macro.
To add your display view to the drop down menu you need to edit every content type. There are two ways of doing this:
1- manually add a "types" folder in the genericsetup profile of your product and put inside one xml file per content type. Ex:
File.xml
<?xml version="1.0"?>
<object name="File"
meta_type="Factory-based Type Information with dynamic views"
i18n:domain="plone" xmlns:i18n="http://xml.zope.org/namespaces/i18n">
<property name="view_methods">
<element value="file_view"/>
<element value="myniewfantastic_view"/>
</property>
</object>
2- in the ZMI -> portal_types edit every content type to add your display view and then in the portal_setup tool export the step for types. Extract the xml definitions from the downloaded archive to your genericsetup profile (in the "types" folder) and then edit them to remove unuseful parts as above.
Sure you can do it. I'm not convinced it's a good idea :-), but you need the <div> to be inside the main_macro (your example HTML is invalid - you have a </tal:main-macro> and no start tag, but I'm assuming you just cut and pasted the last part of the template here, because that template would never display, if it was written that way.
That said, how exactly are you adding it to "the drop-down display menu"?