Blog component doesn't work properly when change the name of page in AEM 6.0 - blogs

I'm working on blog component of AEM 6.0. the problem is when i change the name of parent page i.e blog from blog to blog1 then other components of blogs like pages, authors,archiving stop working . No data comes in these components and if i change the name from blog1 to blog they again work properly. Is there any hardcoding is done for blog name ? if yes can you please specify if i want to change the name of blog how can i resolve it ?

I have similar issue and raise discussion on Adobe Forum
http://help-forums.adobe.com/content/adobeforums/en/experience-manager-forum/adobe-experience-manager.topic.html/forum__hmrl-hi_gents_i_faced.html
My investigations shows that to generate authors,archiving,tags AEM6 uses Lucene search through /var/search-collections/ugc-blog-search that is not updating properly on changing content.
If you are using only components from the box try to modify you content via pageManager e.g. copy
pageManager.copy(pageManager.getPage('/content/geometrixx/en/blog'), '/content/geometrixx/en/blog_pm' , 'blog_pm', false, true);
That may help. In case you are working with custom components based on SCF API it is still unpredictable behavior.

Related

Magento new products widget shows new products twice

I've added a widget to my Magento (1.9.x) homepage Page by adding this to the content source:
{{widget type="catalog/product_widget_new" display_type="new_products" products_count="5" template="catalog/product/widget/new/content/new_grid.phtml"}}
My new products show up, but they are displayed twice, in two separate HTML blocks. After investigating I can see that it is using both these templates (once after the other):
app/design/frontend/mytheme/main/template/catalog/product/new.phtml
app/design/frontend/mytheme/main/template/catalog/product/widget/new/content/new_grid.phtml
Any ideas why?
It turned out that, in the homepage Page, I already had some "Layout Update XML" defined in my Design for the Page. Not sure why it hadn't showed up until after I added the widget code above to the Content, but I removed it and that fixed the issue.
In the end I actually found & used this http://docs.magento.com/m1/ce/user_guide/cms/widget-new-products-list.html which looks like a better way to do New Products on the homepage anyway (it allows better non-dev admin control).

How are DOM/rendered html and Coded-Ui are related, can coded-ui test a web application without even considering how that page is rendered in DOM?

I want to know how the coded-ui in web application utilizes DOM of that page. Or is it related to that page's rendered html is coming?
Edited: If suppose i have a grid having rows and column and i want to capture any particular column in it, then do coded-ui takes the help of the rendered html in this process (id,tagname etc) ?
you can utilize the htmlcontrols which is listed in below url:
https://msdn.microsoft.com/en-us/library/microsoft.visualstudio.testtools.uitesting.htmlcontrols.aspx
I used codedui jquery extensions available in NuGet here
. Once you will add this dll as a reference you can make use ExecuteScript() method for running a jquery script inside coded-ui. Similary you can make use of other built in members.

Why can't I add an HTML custom attribute to a visualforce page?

I have an control, to which I want to add a custom html attribute called, previousValue.
The Salesforce Developer's Guide assures me that I can do this by prefixing the attribute name with html-.
So I have an element that appears thus:. I also have the docType="html-5.0" attribute in my page control.
However, in Eclipse I get an 'unsupported attribute' error. I have upgraded to the latest force.com IDE; can any one tell me why this isn't working? What else do I need to do?
Thanks.
After much experimentation, the answer to this seems to be that the salesforce developer's guide is inaccurate and the 'hmtl-' prefix is not supported by the <apex:inputField> component. I can add it without a problem to an <apex:outputPanel> component. Don't understand why this should be so and the whole point to using these attributes is to locate data in a relevant place and avoid complex jquery selects to find the data relative to the location at which it is required.

URL Masking in .Net / HTML

I have a website in which I have many categories, many sub-categories within each one and many products within each of those. Since the URLs are very user-unfriendly (they contain a GUID!!!), I would like to use a method which I think is called URL Masking. For example instead of going to catalogue.aspx?ItemID=12343435323434243534, they would go to notpads.htm. This would display the same as going to catalogue.aspx?ItemID=12343435323434243534 would display, somehow.
I know I could do this by creating a file for each category / sub-category (individual products cannot be accessed individually as it is a wholesale site - customers cannot purchase directly from the site). This would be a lot of work as the server would have to update each relevant file whenever a category / sub-category / product visibility changes, or a description changes, a name changes... you get the idea...
I have tried using server-side includes but that doesn't like it when a .aspx file is specified in an html file.
I have also tried using an iframe set to 100% width / height and absolutely positioned left 0 and top 0. This works quite well, but I know there are reasons you should not use this method such as some search engines not coping with it well. I also notice that the title of the "parent" page (notepads.htm) is not the title set in the iframe (logically this is correct - but another issue I need to solve if I go ahead and use this method).
Can anyone suggest another way I could do this, or tell me whether I am going along the right lines by using iframes? Thanks.
Regards,
Richard
PS If this is the wrong name for what I am trying to do then please let me know what it actually is so I can rename / retag it.
Look into URL Rewrites. You can create a regular expression and map it to your true url. For example
http://mysite.com?product=banana
could map to
http://mysite.com?guid=lakjdsflkajkfj3lj3l4923892&asfd=9234983920894893
I believe you mean URL Rewriting.
IIS 7+ has a rewrite module built in that you can use for this kind of thing.
URL Rewriters solve the problem you are describing - When someone requests page A, display page B - in a general way.
But yours is not a general requirement. You seem to have a finite uuid-to-shortname mapping requirement. This is the kind of thing you could or should set up in your app, yourself, rather than inserting a new piece of machinery into your system.
Within a default .aspx page, You'd simply do a lookup on the shortname from the url in a persistent table stored somewhere, and then call Server.Transfer() to the uuid-named page associated to that shortname.
It should be easy to prototype this.

SalesForce.com Display image in S-Control

I need to display an image in an S-Control is SFDC. I would like to be able to reference a static resource like <apex:image url="{!$Resource.TestImage}" />, but that only works in VisualForce pages and I have to modify and existing S-Control (switching to VF is not an option).
What's the best way to accomplish this, so frustrated with the general lack of documentation and hackishness of SFDC development.
Thanks all
You can upload your image to Documents tab and later use normal <img> tag to display it on S-Controls, Visualforce pages and email templates (last one - if this will be an "externally available image"). The generated URL to view it will look somewhat like
https://c.na7.content.force.com/servlet/servlet.FileDownload?file=015A0000001IFxZ
(my test org sits at na7.salesforce.com instance and the last part is gnerated object's ID)