WordPress.org

Ready to get started?Download WordPress

Forums

Code Snippets
[resolved] Suggestion - Bulk Export to PHP (4 posts)

  1. WebEndev
    Member
    Posted 2 years ago #

    The bulk export to XML is a very handy feature.

    Another very handy feature would be have a bulk export of the snippets into a single file, but with non of the XML markup. Make the output 'usable' PHP that could be cut and paste directly from the output file and used again, without having to remove the snippet, code, name, description markup.

    This would allow for quick and easy recycling of each snippet, in the event the user was not using the Code Snippets plugin on the next site.

    Thanks for the plugin, it is proving very handy!

    http://wordpress.org/extend/plugins/code-snippets/

  2. Shea Bunge
    Member
    Plugin Author

    Posted 2 years ago #

    That's a nice idea, I don't think that it would be very hard to implement. Maybe in a future version of Code Snippets.

  3. WebEndev
    Member
    Posted 2 years ago #

    Great, I'll be looking for it.
    Thanks Shea :)

  4. Shea Bunge
    Member
    Plugin Author

    Posted 1 year ago #

    This feature landed in version 1.5.

    You can export snippets to a PHP file by checking the checkboxes of the desired snippets and selecting 'Export to PHP' from the Bulk Actions drop-down menu.

    The exported PHP file will contain the snippet's name and description in multi-line PHP comments, and below that the snippet's code. This process is repeated for each snippet you choose to export.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.