Difference between revisions of "PT Photo Gallery CCAPI Configuration"

From ADF Docs
Jump to: navigation, search
(Setup)
 
(12 intermediate revisions by 2 users not shown)
Line 5: Line 5:
  
 
== Setup ==
 
== Setup ==
# Create a new page called 'ccapiPhoto'. Recommend creating this page in the ''photogalleryadmin'' subsite.  
+
# Create a new page called 'ccapiPhoto'. Recommend creating this page in the ''/webadmin/photogallery/'' subsite.  
 
# Add the 'Photo' element to the page.
 
# Add the 'Photo' element to the page.
 
# Select the 'Photo' element indicator and go to 'more...'.  Select 'Name' from the menu.
 
# Select the 'Photo' element indicator and go to 'more...'.  Select 'Name' from the menu.
Line 11: Line 11:
 
# Publish this page and view in read mode.
 
# Publish this page and view in read mode.
 
# Edit the 'ccapi.xml' file for the site and add the following xml block into the <elements> section:
 
# Edit the 'ccapi.xml' file for the site and add the following xml block into the <elements> section:
<pre>
+
<source lang="xml">
  <Photo>
+
<Photo>
    <pageID>#####</pageID>
+
  <pageID>#####</pageID>
    <subsiteID>##</subsiteID>
+
  <subsiteID>##</subsiteID>
    <elementType>custom</elementType>
+
  <elementType>custom</elementType>
    <controlName>ccapiPhotoElement</controlName>
+
  <controlName>ccapiPhotoElement</controlName>
  </Photo>
+
</Photo>
</pre>
+
</source>
 +
 
 
To populate the <pageID> and <subsiteID> tags, view the source code for the 'ccapiPhoto' page that was just created.  
 
To populate the <pageID> and <subsiteID> tags, view the source code for the 'ccapiPhoto' page that was just created.  
 
   
 
   
 
Identify the following line in the source code and enter this numeric value into the <subsiteID> tag:
 
Identify the following line in the source code and enter this numeric value into the <subsiteID> tag:
<pre>
+
<source lang="java">
  var jsSubSiteID = ##;
+
var jsSubSiteID = ##;
</pre>
+
</source>
  
 
Identify the following line in the source code and enter this numeric value into the <pageID> tag:
 
Identify the following line in the source code and enter this numeric value into the <pageID> tag:
<pre>
+
<source lang="java">
  var jsPageID = ####;
+
var jsPageID = ####;
</pre>
+
</source>
 
 
The ADF needs to be reset for the server and site for these CCAPI updates to take effect. Enter the following URL parameter string to any page call within the site:
 
<pre>  ?resetServerADF=1&resetSiteADF=1</pre>
 
  
'''Note: Resetting the ADF server might affect all sites implementing the ADF.'''  If an error occurs, this could cause sites to go down.  Needless to say, updates to the ADF Bean Configs and config files should be done in a controlled development environment (not on production servers!).
+
[[Reset ADF|Reset the ADF]] for the server and site.
  
 
[[Category:Photo Gallery]]
 
[[Category:Photo Gallery]]

Latest revision as of 19:25, 26 March 2010

Overview

The Photo Gallery Application uses the ADF CCAPI to populate profile records and create profile pages. The CCAPI needs to be configured for the site and photo gallery application.

First, follow the steps to set up the CCAPI Config file for the site. Once that configuration is complete, follow the steps below to set up the CCAPI config for the Photo Gallery application. Make sure to update the wsVars section with the correct URLs and username/password.

Setup

  1. Create a new page called 'ccapiPhoto'. Recommend creating this page in the /webadmin/photogallery/ subsite.
  2. Add the 'Photo' element to the page.
  3. Select the 'Photo' element indicator and go to 'more...'. Select 'Name' from the menu.
  4. In the Element Name field, enter the text 'ccapiPhotoElement'.
  5. Publish this page and view in read mode.
  6. Edit the 'ccapi.xml' file for the site and add the following xml block into the <elements> section:
<Photo>
  <pageID>#####</pageID>
  <subsiteID>##</subsiteID>
  <elementType>custom</elementType>
  <controlName>ccapiPhotoElement</controlName>
</Photo>

To populate the <pageID> and <subsiteID> tags, view the source code for the 'ccapiPhoto' page that was just created.

Identify the following line in the source code and enter this numeric value into the <subsiteID> tag:

var jsSubSiteID = ##;

Identify the following line in the source code and enter this numeric value into the <pageID> tag:

var jsPageID = ####;

Reset the ADF for the server and site.