Plugin Directory

Changeset 494648


Ignore:
Timestamp:
01/24/2012 03:52:48 PM (14 years ago)
Author:
Wolfram Research
Message:

Improved integration with WordPress media uploader.

Location:
wolfram-cdf-plugin/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • wolfram-cdf-plugin/trunk/WolframCDF.php

    r413329 r494648  
    44Plugin URI: http://www.wolfram.com
    55Description: Simple plugin to insert CDF into the Wolfram Blog
    6 Version: 1.0
     6Version: 1.1
    77Author: Dan Sherman/Cole Berkley
    88Author URI: http://www.wolfram.com
     
    1414add_action('admin_print_scripts', 'addWriCDFShortCode');
    1515add_action('wp_print_scripts', 'addCDFJs');
     16add_filter('upload_mimes', 'addCDFUpload');
    1617
    1718//used to replace " in altcont to keep non-technical users from breaking
    1819//the plugin
    1920$replacement = '&QUOTE&';
     21
     22//allows uploading of cdf mime type
     23function addCDFUpload($currentMimes=array()){
     24    $currentMimes['cdf'] = 'application/vnd.wolfram.cdf .cdf';
     25    return $currentMimes;
     26}
    2027
    2128//adds in the necessary javascript
  • wolfram-cdf-plugin/trunk/readme.txt

    r413721 r494648  
    1 === Wolfram CDF Plugin===
    2 Contributors: Wolfram Research
    3 donate link: http://www.wolfram.com/cdf/
     1=== Plugin Name ===
     2Contributors: cberkley
     3donate link: http://www.wolfram.com
    44Tags: CDF, Computable Document Format, Wolfram Research, Mathematica, Wolfram
    55Requires at least: 2.8.2
    6 Tested up to: 2.8.2
     6Tested up to: 1.0
    77Stable tag: 1.0
    88
    9 The Wolfram CDF Plugin is a simple robust plugin that lets users include interactive Computable Document Format (CDF) documents in their blogs.
     9The Wolfram CDF Plugin is a simple robust plugin that allows users to place CDF Documents on their WordPress Blogs.
    1010
    1111== Description ==
    1212
    13 The Wolfram CDF Plugin adds a Wolfram CDF Player button to the WordPress HTML post editor. 
     13The Wolfram CDF Plugin adds a CDF Player button to the WordPress HTML post editor. 
    1414
    15 To use this plugin, open the post you wish to edit and choose the HTML tab on the editor. Then click
    16 the editor where you want the plugin to appear and press the CDF button. The following placeholder text will appear in the place you have selected:
     15To use this plug-in, open up a post you wish to edit, choose the html tab on the editor click.  Then, click on in
     16the editor where you want the plugin to be and press the cdf button.  Upon doing so placeholder text will be
     17appear where the in the place you have selected.
     18
     19This text will appear as:
    1720
    1821[WolframCDF source="file" CDFwidth="w" CDFheight="h" altimage="file"]
    1922
    20 [WolframCDF] marks the text that will be replaced with the content of your CDF.
     23[WolframCDF ] marks the text which gets parced and replaced witht he cdf.
    2124
    22 There are several attributes that must be set in order for your plugin to appear on the page successfully.
     25The are several attributes which must be set in order for your plug-in to appear on thepage successfully.
    2326
    24 ##### Source
     271. Source:
     28Required: Yes
     29Input type(s): file name with extension, url
     30Description: Source holds the CDF file name or the url where the file is located.  If you wish to enter just the file's name,
     31you must first upload the file to wordpress using the fileuploader. 
    2532
    26 * Required: Yes
    27 * Input type(s): file name with extension, URL
    28 * Description: Source holds the CDF file name or the URL where the file is located. If you wish to enter only the file name, you must first upload the file to WordPress using the file uploader. 
     332. CDFwidth:
     34Required: Yes
     35Input type(s): integer
     36Description: CDFwidth holds an integer number that describes the width in pixels of the CDF file you wish to show on your
     37WordPress blog.
    2938
    30 ##### CDFwidth
     393. CDFheight:
     40Required: yes
     41Input type(s): integer
     42Description: CDFheight holds an integer number that describes the height in pixels of the CDF file you wish to show on your
     43WordPress blog.
    3144
    32 * Required: Yes
    33 * Input type(s): integer
    34 * Description: CDFwidth holds an integer that describes the width in pixels of the CDF content you wish to embed in your WordPress blog.
     454. altimage:
     46Required: no
     47Input type(s): file name with extension, url
     48Description: altimage stores an image which will be displayed if the client has not installed the CDF plugin.  If left
     49blank a default image will appear.  This attribute is over ridden by altcont.
    3550
    36 ##### CDFheight
     515. altcont:
     52Required: no
     53Input type(s): plain text, html
     54Description: altcont stores text or html which will be displayed if the client has not installed the CDF plugin.  If left
     55blank a default image is appear.
    3756
    38 * Required: yes
    39 * Input type(s): integer
    40 * Description: CDFheight holds an integer that describes the height in pixels of the CDF content you wish to embed in your WordPress blog.
    41 
    42 ##### altimage
    43 
    44 * Required: no
    45 * Input type(s): file name with extension, URL
    46 * Description: altimage stores an image that will be displayed if the client has not installed the CDF Player browser plugin. If left blank, a default image will appear. This attribute can be overridden by altcont.
    47 
    48 ##### altcont
    49 
    50 * Required: no
    51 * Input type(s): plain text, HTML
    52 * Description: altcont stores text or HTML that will be displayed if the client has not installed the CDF Player browser plugin. 
    53 
    54 The final text will appear similar to the following:
    55 [WolframCDF source="MyFile.cdf" CDFwidth="516" CDFheight="320" altimage="MyFilePic.png"]
    56 
    57 Once the placeholder text has been entered and the attributes have been filled out, press the Preview button to view the content or the Publish/Update post button to submit the post with the CDF content.
    58 
    59 Note: WordPress 3.1.3 and up currently strips the JavaScript tags from the CDF plugin code in the excerpt of a post. The CDF will appear correctly when the full post is viewed. We recommend including CDF content after the more tag until we resolve this issue.
     57Once the place holder text has been entered and the attributes have been filled out press the Publish/Update post button
     58or the Preview button to view the content.
    6059
    6160== Installation ==
    6261
    63 = Automatic =
     62=Automatic=
     631. Download the zip file of the plugin which can be found by going to http://wordpress.org/extend/plugins/ and searching for
     64CDF.
     652. Log in to the admin pages of your site and click on Plugins->Add New->Upload.  Then brows for the zip file you downloaded
     66and press Install Now.
     673. Click on the 'installed' link under 'Plugins' and activate the Wolfram CDF Plugin.
    6468
    65 1. Download the ZIP file of the plugin, which can be found by searching "CDF" on the WordPress Plugin Directory:
    66 http://wordpress.org/extend/plugins
    67 2. Log in to the admin pages of your site and click Plugins->Add New->Upload. Then browse for the ZIP file you downloaded and press Install Now.
    68 3. Click the "installed" link under "Plugins" and activate the Wolfram CDF Plugin.
    69 
    70 = Manual =
    71 
    72 1. Download the ZIP file of the plugin, which can be found by searching "CDF" on the WordPress Plugin Directory:
    73 http://wordpress.org/extend/plugins
    74 2. Upload the ZIP file to the /wp-content/plugins directory.
    75 3. Log in to the wp-admin page of your WordPress blog.
    76 4. Click Plugins->Installed and activate the Wolfram CDF Plugin.
     69=Manual=
     701. Download the zip file of the plugin which can be found by going to http://wordpress.org/extend/plugins/ and searching for
     71CDF.
     722. Upload the zip file to the `/wp-content/plugins/` directory
     733. Log in to the wp-admin page of your wordpress blog.
     744. Click on Plugins->Installed and activate the Wolfram CDF Plugin.
    7775
    7876== Frequently Asked Questions ==
    7977
    80 = What does CDF stand for? =
     78= What does CDF Stand for? =
    8179
    82 CDF is Computable Document Format, used to develop interactive apps, reports, presentations, books, and courseware to give ideas a broad communication pipeline.
     80Computable Document Format
    8381
    8482= How do I create CDF documents? =
    8583
    86 You create CDF documents through Mathematica, a development platform fully integrating computation into complete workflows. For more information, please visit:
    87 http://www.wolfram.com/mathematica
     84You create CDF documents through a probram called Mathematica.  For more information please please visit
     85http://www.wolfram.com/mathematica/
    8886
    89 = How do I publish a CDF document to my site without this plugin? =
    90 You can embed CDFs on any website or display them as full-screen documents. For more information, please visit:
    91 http://www.wolfram.com/cdf/adopting-cdf/deploying-cdf/web-delivery.html
     87= How do I publish A CDF document to my site without this plugin? =
     88For information on this topic please visit http://www.wolfram.com/cdf/adopting-cdf/deploying-cdf/web-delivery.html
    9289
    9390== Screenshots ==
    9491
    95 1. screenshot-1.png shows the input to the HTML editor in wp-admin.
     921. screenshot-1.png shows the the the input to the html editor in wp-admin.
    96932. screenshot-2.png shows the outcome of screenshot-1.png.
    9794
     
    10299* Allowed for file name only to be entered into the source attribute.
    103100
     101= 1.2 =
     102* Improved integration with WordPress media uploader.
     103
    104104= 0.5 =
    105105* Original version
     
    108108== Upgrade Notice ==
    109109
    110 = 1.0 =
    111 Version 1.0 allows you to include interactive CDF documents in your WordPress blog.
     110= 1.2 =
     111Version 1.2 allows you to add CDF Documents to you WordPress Blog
Note: See TracChangeset for help on using the changeset viewer.