how to refresh a page of full data population automatically - content-management-system

I have a list of data which are been read from an xml file(in dam) in a component and suppose get populated in the entire page. As soon as I read the file in the component, it refreshes the page due to editConfig setting, however, in order see the full data the page(read from xml), I have to do a manual refresh again in the browser.
Is there a way to automate the entire process such that manual refresh can be done away with.
Here is the editConfig setting:
<jcr:root xmlns:cq="http://www.day.com/jcr/cq/1.0" xmlns:jcr="http://www.jcp.org/jcr/1.0"
cq:dialogMode="floating"
cq:disableTargeting="{Boolean}true"
jcr:primaryType="cq:EditConfig">
<cq:listeners
jcr:primaryType="cq:EditListenersConfig"
afteredit="REFRESH_PAGE"/>

I think this might be an useful solution for your problem.
https://adobe-consulting-services.github.io/acs-aem-tools/features/live-reload.html

Related

Why does my ClientLibrary css file keep including Bootstrap?

In CQ5, I've made a clientLibrary for one of my pages. Even when I remove all embed's and dependencies, the output .css file that gets loaded by my page has bootstrap at the top of the file. The client library itself just has a few js and css files that don't include or require bootstrap in any way. Am I missing something? Also I'm noticing the js file this clientLib outputs includes lot of scripts from my libraries that I'm not including in the clientLib or calling as a dependency/embed.
Below is my clientLibs .content.xml file.
<?xml version="1.0" encoding="UTF-8"?>
<jcr:root
xmlns:cq="http://www.day.com/jcr/cq/1.0"
xmlns:jcr="http://www.jcp.org/jcr/1.0"
jcr:primaryType="cq:ClientLibraryFolder"
categories="[apps.myPage]" />
AEM saves the compiled clientlibs in a cache. Sometimes it happens the invalidation of the cache is not triggered. With using the following url you can execute the invalidation or the rebuild of your clientlibs:
/libs/granite/ui/content/dumplibs.rebuild.html
Is your problem not solved check the clientlib setup at the following page.
/libs/granite/ui/content/dumplibs.html
This page gives you insight about the embeds and dependencies on your clientlib. Probably a the reference still exists.
Everything configured well and it still doesnt work? In that case change the jcr:nodename of your clientlib folder. Check it once again.. Does it work, change back the name and it will work ;)

How to merge two prototypes in Pencil Wireframing Tool?

I am using Pencil wire framing tool. I have distributed the modules with my developers and now I want to merge all of them in a single solution. Instead of copy pasting page by page I think there can be a better way of doing this.
Also I wanted to know, is it possible of converting the one source file of prototype into another as I think collaboration feature in Pencil is missing.
Please assist.
Thank you
Open .ep files in your favorite editor. You will see an XML structure like
<?xml version="1.0"?>
<Document xmlns="http://www.evolus.vn/Namespace/Pencil">
<Properties/>
<Pages>
<page>...</page>
<page>...</page>
.....
.....
</Pages>
</Document>
Now just copy paste second .ep files all <page> at end of first .ep (Just before </pages>

TYPO3 won't update front-end page after external TypoScript modification

I am trying to edit a .ts file through the Quixplorer.
I click on edit, add the link and hit save. But it does not get updated on the actual page.
When I click a preview of the file within the Quixplorer i can see my change but it just won't show on the homepage...
Any ideas?
While editing *.ts files it is always required to clear whole cache from the backend, to take changes into account.
Also make sure, that you're modifying correct file. The often mistake is editing files which aren't included to the DB TS template. You can verify that with the Template module (after cache clearing).

How to export data from Chrome developer tool?

Network analysis by Chrome when page loads
I would like to export this data to Microsoft Excel so that I will have a list of similar data when loaded at different times. Loading a page one time doesn't really tell me much especially if I want to compare pages.
if you right click on any of the rows you can export the item or the entire data set as HAR which appears to be a JSON format.
It shouldn't be terribly difficult to script up something to transform that to a csv if you really need it in excel, but if you're already scripting you might as well just use the script to ask your questions of the data.
If anyone knows how to drive the "load page, export data" part of the process from the command line I'd be quite interested in hearing how
from Chrome 76, you have Import/Export buttons.
I was trying to copy the size data measured from Chrome Network and stumbled on this post. I just found an easier way to "export" the data out to excel which is to copy the table and paste to excel.
The trick is click Control + A (select all) and once the entire table will be highlighted, paste it to Microsoft Excel. The only issue is if there are too many fields, not all rows are copied and you might have to copy and paste several times.
UPDATED: I found that copying the data only works when I turn off the filter options (the funnel-looking button above the table). – bendur
Right-click and export as HAR, then view it using Jan Odvarko's HAR Viewer
This helps in visualising the already captured HAR logs.
I came across the same problem, and found that easier way is to undock the developer tool's video to a separate window! (Using the right hand top corner toolbar button of developer tools window)
and in the new window , simply say select all and copy and paste to excel!!
In Chrome, in the Developer Tools, under Network, in the Name column, right-click and select "Save as HAR with content". Then open a new tab, go to https://toolbox.googleapps.com/apps/har_analyzer/ and open the saved HAR file.
Note that &Lt;Copy all as HAR&Gt; does not contain response body.
You can get response body via &Lt;Save as HAR with Content&Gt;, but it breaks if you have any more than a trivial amount of logs (I tried once with only 8k requests and it doesn't work.) To solve this, you can script an output yourself using _request.contentData().
When there's too many logs, even _request.contentData() and &Lt;Copy response&Gt; would fail, hopefully they would fix this problem. Until then, inspecting any more than a trivial amount of network logs cannot be properly done with Chrome Network Inspector and its best to use another tool.
You can use fiddler web debugger to import the HAR and then it is very easy from their on... Ctrl+A (select all) then Ctrl+c (copy summary) then paste in excel and have fun
I don't see an export or save as option.
I filtered out all the unwanted requests using -.css -.js -.woff then right clicked on one of the requests then Copy > Copy all as HAR
Then pasted the content into a text editor and saved it.
I had same issue for which I came here. With some trials, I figured out for copying multiple pages of chrome data as in the question I zoomed out till I got all the data in one page, that is, without scroll, with very small font size. Now copy and paste that in excel which copies all the records and in normal font.
This is good for few pages of data I think.
In more modern versions of Chrome you can just drag a .har file into the network tab of Chrome Dev Tools to load it.
To get this in excel or csv format- right click the folder and select "copy response"- paste to excel and use text to columns.
You can try use Haiphen, which is a chrome extension that allows you to analyze network traffic and what API calls a web application is making.

Making Word document embedded in a web page editable or read-only

I'm embedding some Word documents into our web page using iframe like this:
<iframe src="ftp://ftp.example.com/www/uploads/Image/test.doc" width="100%" height="400">
Alternative
</iframe>
The problem is that the embedded Word control allows the user to edit the documents and shows an icon to save them, but doesn't actually save anything. Is it possible to setup Word to save edits back to the FTP server? If not, is there someway we can make the document read-only so the user doesn't get the idea that they can make changes? We're using IE7 and Word 2003.
(I just asked a related question about getting Word to save to a FTP server: Possible for Word to edit documents directly off an web server without Sharepoint?)
You can use ActiveX component like EDraw OfficeView or UltraOffice to embbed office and give you few control against the save and edit the document. You can also send it back to server for save.
There are a number of solutions to your problem, the easiest in my oppinion is a commercial app: https://crocodoc.com/. Developers have unlimited preview time but production use requires a license, don't know if thats an option in your case? To get this working in IE7 you will also need http://html5boilerplate.com/ together with http://code.google.com/p/html5shiv/.
Not sure if this solution will remain free but it is at the moment: https://cloudconvert.org/page/api. They provide an api to convert documents to html, you could write a script to convert docs to html on upload and then store html to show on site.
Another good option is http://www.phpdocx.com/ they have a conversion plugin to convert docx to HTML, pdf and such.
As for making your existing solution read only, i read somewhere you can do it with the method below but i am unable to test as i am on a mac and currently have no access to a machine with IE right now.
<object id="msword" width="100%" height="100%" classid="clsid:67F2A879-82D5-4A6D-8CC5-FFB3C114B69D" data='[insert document name].doc'>
<PARAM NAME="src" VALUE="file:////[insert full document path here].doc" >
<PARAM NAME="readonly" value=true>
</object>
Hope these suggestions help you with your project!
I would recommend converting the file to an mht file. this will provide cleaner lines when shown in the browser and prevent the user from editing or saving the file.