Show TOC

Procedure documentationSearch Engine Indexing Locate this document in the navigation structure

 

You can enable search engines to index pages in the external facing portal, because the light framework page consists of a single frame, and light content is static.

A user agent is an application that is used to browse the Web. Web user agents can be Web browsers or search engine crawlers, or even accessibility products such as screen readers.

When a user agent accesses a Web site, it provides information about itself, such as the brand and version of the browser. When a search engine "reads" portal content, it in effect tries to display the content. However, only user agents supported by the SAP Product Availability Matrix (PAM) can display portal content, so instead of retrieving content and indexing it, the search engine user agent receives an error.

Note Note

For information about supported browsers, see the Product Availability Matrix at service.sap.com/pam.

End of the note.

To allow search engines to access portal pages you need to change the portal's configuration to provide access to all user agents. The SupportedUserAgents property defines which browsers can access the portal. You need to modify this property in all of the pages and iViews that contain content that you want indexed, as well as in all of the portal desktop components. The following components comprise the portal desktop:

  • Framework Page

  • All iViews in the Framework Page

  • Desktop Innerpage

  • All iViews in the Desktop Innerpage

  • Framework Layout

  • Navigation Panel and Content Area Layout

You can modify the SupportedUserAgents property for all of the relevant components simultaneously using the Find & Replace Wizard.

After you have modified the SupportedUserAgents property, you need to perform a number of actions in the NetWeaver Developer Studio to allow search engines to crawl and index portal pages.

Prerequisites

Caution Caution

If used incorrectly, the Find & Replace Wizard can irreversibly damage an entire portal or parts of it. Make sure that you read Finding and Replacing Object Properties before working with the wizard.

End of the caution.
  • To view objects in the wizard's result set, you must have at least administrator read permissions for each object. See Permission Levels.

  • To be able to change the properties of an object, you must have at least administrator read/write permission for each object.

Procedure

Modify the SupportedUserAgents Property
  1. In the portal, navigate to Content Administration.

  2. At the top of the Portal Catalog, choose Find & Replace.

    The Find & Replace wizard opens.

  3. Change the value of the SupportedUserAgents property to (*,*,*).

More information: Finding and Replacing Object Properties

Allow Search Engines to Crawl and Index All Portal Pages-Example

Different search engines use different methods to rank content so that it can be found by the search engine.

In the following example, you enable the Google search engine to crawl and index all portal pages. Other search engines may require different configuration.

Recommendation Recommendation

This procedure is optional. Allowing or blocking search engines and web crawlers is subject to your company's internal policies. We recommend blocking sensitive web content by adding a robots.txt file to the root of your site hierarchy and define a policy regarding the HTML pages of the portal that are exposed to the web.

For example, the following keeps all crawlers out:

User-agent: *

Disallow: /

End of the recommendation.
  1. In the NetWeaver Developer Studio, create a new portal application.

  2. Open the PORTAL-INF/portalapp.xml file, and exchange its contents with the following:

    Syntax Syntax

    1. <?xml version="1.0" encoding="utf-8"?>
    2. <application alias="google">
    3.   <application-config>
    4.     <property name="Vendor" value="sap.com"/>
    5.     <property name="SecurityArea" value="NetWeaver.Portal"/>
    6.     <property name="SharingReference" value="com.sap.portal.navigation.navigationtaglibrary"/>
    7.   </application-config>
    8.   <components>
    9.     <component name="sitemap">
    10.       <component-config>
    11.         <property name="SecurityZone" value="com.sap.portal/no_safety"/>
    12.         <property name="ComponentType" value="jspnative"/>
    13.         <property name="JSP" value="jsp/sitemap.jsp"/>
    14.       </component-config>
    15.       <component-profile>
    16.         <property name="EPCFLevel" value="0"/>
    17.         <property name="AuthScheme" value="anonymous"/>
    18.         <property name="NavigationTagLibrary" value="/SERVICE/com.sap.portal.navigation.navigationtaglibrary/taglib/TagLibrary.tld"/>
    19.       </component-profile>
    20.     </component>
    21.   </components>
    22.   <services/>
    23. </application>
    End of the code.
  3. Create a new file named PORTAL-INF/jsp/sitemap.jsp and paste the following text:

    Syntax Syntax

    1. <%@ taglib uri="NavigationTagLibrary" prefix="nav"%>
    2. <nav:iterateInitialNavNodes>
    3.   <nav:recurseNavNodeChildren>
    4.     <br><nav:navNodeAnchor navigationMethod="byURL" />
    5.   </nav:recurseNavNodeChildren>
    6. </nav:iterateInitialNavNodes>
    End of the code.
  4. Upload the new application

  5. Insert the following in the HTML of the Top-Level Navigation iView (com.sap.portal.navigation.toplevel/PORTAL-INF/pagelet /toplevelnavigation.jsp):

    Syntax Syntax

    1. <a href="/irj/servlet/prt/portal/prtroot/google.sitemap" style="position:absolute;top:-99999px">Sitemap</a>
    End of the code.