~ubuntu-branches/ubuntu/natty/moin/natty-updates

« back to all changes in this revision

Viewing changes to wiki/htdocs/applets/FCKeditor/_samples/php/sample01.php

  • Committer: Bazaar Package Importer
  • Author(s): Jonas Smedegaard
  • Date: 2008-06-22 21:17:13 UTC
  • mto: This revision was merged to the branch mainline in revision 18.
  • Revision ID: james.westby@ubuntu.com-20080622211713-inlv5k4eifxckelr
ImportĀ upstreamĀ versionĀ 1.7.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?php 
 
2
/*
 
3
 * FCKeditor - The text editor for internet
 
4
 * Copyright (C) 2003-2005 Frederico Caldeira Knabben
 
5
 * 
 
6
 * Licensed under the terms of the GNU Lesser General Public License:
 
7
 *              http://www.opensource.org/licenses/lgpl-license.php
 
8
 * 
 
9
 * For further information visit:
 
10
 *              http://www.fckeditor.net/
 
11
 * 
 
12
 * "Support Open Source software. What about a donation today?"
 
13
 * 
 
14
 * File Name: sample01.php
 
15
 *      Sample page.
 
16
 * 
 
17
 * File Authors:
 
18
 *              Frederico Caldeira Knabben (fredck@fckeditor.net)
 
19
 */
 
20
 
 
21
include("../../fckeditor.php") ;
 
22
?>
 
23
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
 
24
<html>
 
25
        <head>
 
26
                <title>FCKeditor - Sample</title>
 
27
                <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 
28
                <meta name="robots" content="noindex, nofollow">
 
29
                <link href="../sample.css" rel="stylesheet" type="text/css" />
 
30
        </head>
 
31
        <body>
 
32
                <h1>FCKeditor - PHP - Sample 1</h1>
 
33
                This sample displays a normal HTML form with an FCKeditor with full features 
 
34
                enabled.
 
35
                <hr>
 
36
                <form action="sampleposteddata.php" method="post" target="_blank">
 
37
<?php
 
38
// Automatically calculates the editor base path based on the _samples directory.
 
39
// This is usefull only for these samples. A real application should use something like this:
 
40
// $oFCKeditor->BasePath = '/FCKeditor/' ;      // '/FCKeditor/' is the default value.
 
41
$sBasePath = $_SERVER['PHP_SELF'] ;
 
42
$sBasePath = substr( $sBasePath, 0, strpos( $sBasePath, "_samples" ) ) ;
 
43
 
 
44
$oFCKeditor = new FCKeditor('FCKeditor1') ;
 
45
$oFCKeditor->BasePath   = $sBasePath ;
 
46
$oFCKeditor->Value              = 'This is some <strong>sample text</strong>. You are using <a href="http://www.fckeditor.net/">FCKeditor</a>.' ;
 
47
$oFCKeditor->Create() ;
 
48
?>
 
49
                        <br>
 
50
                        <input type="submit" value="Submit">
 
51
                </form>
 
52
        </body>
 
53
</html>
 
 
b'\\ No newline at end of file'