Inserting XSLT fragments in dynamic pages

Inserting XSLT fragments in dynamic pages

Once you have created an XSLT fragment, you can insert it in a dynamic web page using the XSL Transformation server behavior. When you add the server behavior to your page and view the page in a browser, an application server performs a transformation that displays the XML data from the selected XSLT fragment. Dreamweaver supports XSL transformations for ColdFusion, ASP, ASP.NET, or PHP pages.

To insert an XSLT fragment in a web page:

  1. Open an existing ColdFusion, ASP, ASP.NET, or PHP page.
  2. In Design view, place the insertion point in the location where you want to insert the XSLT fragment.
  3. In the Server Behaviors panel (Window > Server Behaviors), click the Plus (+) button and select XSL Transformation.

    This is a picture of the feature being described.

  4. In the XSL Transformation dialog box, click the Browse button and browse to an XSLT fragment or an entire XSLT page. For more information, see Creating XSLT pages.

    Dreamweaver automatically populates the next text field with the file path or URL of the XML file that is attached to the specified fragment. To change it, click the Browse button and browse to another file.

  5. (Optional) Click the Plus (+) button to add an XSLT parameter. For more information, see Using parameters with XSL transformations.
  6. Click OK.

    Dreamweaver inserts a reference to the XSLT fragment in the page. The fragment is not editable. You can double-click the fragment to open the fragment’s source file and edit it.

    Dreamweaver also creates an includes/MM_XSLTransform/ folder in the site’s root folder that contains a runtime library file. The application server uses the functions defined in this file to perform the transformation. For more information, see About server-side XSL transformations.

  7. Upload the dynamic page to your server (Site > Put). When Dreamweaver gives you the option of including dependent files, click Yes. The file containing the XSLT fragment, the XML file containing your data, and the generated run-time library file must all be on the server for your page to display correctly. (If you selected a remote XML file as your data source, that file must of course reside somewhere else on the Internet.)

Related topics

  • Creating XSLT pages
  • Deleting XSLT fragments from dynamic pages
  • About using XML and XSL with web pages


Getting Started with Dreamweaver
Dreamweaver Basics
Working with Dreamweaver Sites
Laying Out Pages
Adding Content to Pages
Working with Page Code
Preparing to Build Dynamic Sites
Making Pages Dynamic
Defining Sources of Dynamic Content
Developing Applications Rapidly
 
ASPTreeView.com
 
Evaluation has Ч»КЪіБјјexpired.
Info...