Title: Insert PHP Code Snippet
Author: f1logic
Published: <strong>16 בספטמבר 2013</strong>
Last modified: 16 במרץ 2026

---

חיפוש תוספים

![](https://ps.w.org/insert-php-code-snippet/assets/banner-772x250.jpg?rev=1800967)

![](https://ps.w.org/insert-php-code-snippet/assets/icon-128x128.png?rev=1800967)

# Insert PHP Code Snippet

 מאת [f1logic](https://profiles.wordpress.org/f1logic/)

[הורדה](https://downloads.wordpress.org/plugin/insert-php-code-snippet.1.4.5.zip)

 * [פרטים](https://he.wordpress.org/plugins/insert-php-code-snippet/#description)
 * [סקירות](https://he.wordpress.org/plugins/insert-php-code-snippet/#reviews)
 *  [התקנה](https://he.wordpress.org/plugins/insert-php-code-snippet/#installation)
 * [פיתוח](https://he.wordpress.org/plugins/insert-php-code-snippet/#developers)

 [תמיכה](https://wordpress.org/support/plugin/insert-php-code-snippet/)

## תיאור

A quicklook into Insert PHP Code Snippet

    ```
    ★ Convert PHP snippets to shortcodes
    ★ Insert PHP code easily using shortcode
    ★ Support for PHP snippet shortcodes in widgets
    ★ Dropdown menu in TinyMCE editor to pick snippet shortcodes easily
    ```

#### Features in Detail

Insert PHP Code Snippet allows you to create shortcodes corresponding to PHP code
snippets. You can create a shortcode corresponding to any random PHP code such as
ad codes, login validation etc. and use the same in your posts, pages or widgets.

The shortcodes generated using the plugin are easily available as a dropdown in 
the standard wordpress content editor as well as in widget settings, thereby giving
you ease of integrating your PHP snippets with your posts and pages.

#### About

Insert PHP Code Snippet is developed and maintained by [XYZScripts](http://xyzscripts.com/).
For any support, you may [contact us](http://xyzscripts.com/support/).

★ [Insert PHP Code Snippet User Guide](http://help.xyzscripts.com/docs/insert-php-code-snippet/user-guide)

★ [Insert PHP Code Snippet FAQ](http://help.xyzscripts.com/docs/insert-php-code-snippet/faq/)

### More Information

★ [Insert PHP Code Snippet User Guide](http://help.xyzscripts.com/docs/insert-php-code-snippet/user-guide)

★ [Insert PHP Code Snippet FAQ](http://help.xyzscripts.com/docs/insert-php-code-snippet/faq/)

#### Troubleshooting

Please read the FAQ first if you are having problems.

#### Requirements

    ```
    WordPress 5.0+
    PHP 7+
    ```

#### Feedback

We would like to receive your feedback and suggestions. You may submit them at our
[support desk](http://xyzscripts.com/members/support/).

## צילומי מסך

 * [[
 * This is the shortcode generator page
 * [[
 * This is page where you can manage all your snippets
 * [[
 * The shortcodes are easily accessible in the content editor

## התקנה

★ [Insert PHP Code Snippet User Guide](http://help.xyzscripts.com/docs/insert-php-code-snippet/user-guide)

★ [Insert PHP Code Snippet FAQ](http://help.xyzscripts.com/docs/insert-php-code-snippet/faq/)

 1. Extract `insert-php-code-snippet.zip` to your `/wp-content/plugins/` directory.
 2. In the admin panel under plugins activate Insert PHP Code Snippet.

If you need any further help, you may contact our [support desk](http://xyzscripts.com/support/).

## שאלות נפוצות

★ [Insert PHP Code Snippet User Guide](http://help.xyzscripts.com/docs/insert-php-code-snippet/user-guide)

★ [Insert PHP Code Snippet FAQ](http://help.xyzscripts.com/docs/insert-php-code-snippet/faq/)

### 1. The Insert PHP Code Snippet is not working properly.

Please check the wordpress version you are using. Make sure it meets the minimum
version recommended by us. Make sure all files of the `insert php code snippet` 
plugin uploaded to the folder `wp-content/plugins/`

### 2. I have 2 PHP shortcodes placed adjacently, but only one of them works.

Please use a whitespace to separate 2 shortcodes.

More questions ? [Drop a mail](http://xyzscripts.com/members/support/) and we shall
get back to you with the answers.

## סקירות

![](https://secure.gravatar.com/avatar/011ee8c304c928ab0bc93abcb86e79293407600393daa578546e12843dfa4088?
s=60&d=retro&r=g)

### 󠀁[今までの中で一番良いです](https://wordpress.org/support/topic/%e4%bb%8a%e3%81%be%e3%81%a7%e3%81%ae%e4%b8%ad%e3%81%a7%e4%b8%80%e7%95%aa%e8%89%af%e3%81%84%e3%81%a7%e3%81%99/)󠁿

 [sea1jp](https://profiles.wordpress.org/sea1jp/) 11 באפריל 2026

何種類か 同様エディター使いましたが 安定していて 一番良いです

![](https://secure.gravatar.com/avatar/a3a1c69e46b37711348220f981eaa445c37fb9f18a9e9be87246069ede8e96f8?
s=60&d=retro&r=g)

### 󠀁[On-Demand Execution seems to throw a json error on line 0](https://wordpress.org/support/topic/latest-update-broke-new-snippet-execution/)󠁿

 [pavman](https://profiles.wordpress.org/pavman/) 18 במרץ 2026 1 reply

This is a great plugin when you don't have errors in php. Just don't re-use functions
with the same name on the same page with menus / widgets that use the snippet or
it will throw a broken site error. Minus 1 star on the latest version as when I 
try to run a snippet on demand I get a json error (but am not using json), regardless
of whether or not that code is already being used somewhere else successfully in
snipet form. What's really cool is you can use a post's custom fields to control
variables in php snippets via:$var = get_post_meta(#_of_post,'name_of_custom_field',
true); And then $someothervar = $$var to access the custom field's raw value to 
make custom variables a snap without having to write an admin interface in the dashboard
for custom variables.

![](https://secure.gravatar.com/avatar/8e56b745d2ab63126174020dd1cfa2d4baa6d13219df04d102531655515dbddf?
s=60&d=retro&r=g)

### 󠀁[Insert PHP Code Snippet saved me](https://wordpress.org/support/topic/insert-php-code-snippet-saved-me/)󠁿

 [jweichel](https://profiles.wordpress.org/jweichel/) 24 בפברואר 2026

I also use a different php snippet program that suddenly had several of my snippets
fail. I loaded this snippet program; and, using the exact same snippet code, it 
worked fine.

![](https://secure.gravatar.com/avatar/8f3e38df7c7ae2204cbe53da5b5c7e7a2f37a47b9eac89da59a2e3c5ec4e0559?
s=60&d=retro&r=g)

### 󠀁[Simple and works well](https://wordpress.org/support/topic/simple-and-works-well-57/)󠁿

 [chazzo](https://profiles.wordpress.org/chazzo/) 10 בפברואר 2026

I wrote some custom code to query an API and display a map of the results. This 
plugin is a simple and fuss-free way to add this to a specific web page using a 
shortcode. In due course we'll probably pay for the version that supports JS as 
well.

![](https://secure.gravatar.com/avatar/b19e091811e9bebb0fc63b810aa98863e755fa6553d71a1e24e30318178f7865?
s=60&d=retro&r=g)

### 󠀁[Fantastic](https://wordpress.org/support/topic/fantastic-3473/)󠁿

 [oelinsfeuer](https://profiles.wordpress.org/oelinsfeuer/) 23 בדצמבר 2025

Love it 🥰

![](https://secure.gravatar.com/avatar/937d71742885813aa1994bafa85e9c007f162aa65116a61c51108e9d9bd23da7?
s=60&d=retro&r=g)

### 󠀁[truly first-class](https://wordpress.org/support/topic/truly-first-class/)󠁿

 [marcoleon346](https://profiles.wordpress.org/marcoleon346/) 26 בנובמבר 2025

It simply does what it is supposed to do. And it does it very well, reliably and
easily. That's how you imagine a helpful plugin to be. Perfect.

 [ קראו את כל 699 הסקירות ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/)

## מפתחים

"Insert PHP Code Snippet" הוא תוסף קוד פתוח. האנשים הבאים תרמו ליצירת התוסף הזה.

תורמים

 *   [ f1logic ](https://profiles.wordpress.org/f1logic/)

[ניתן לתרגם את "Insert PHP Code Snippet" לשפה שלך.](https://translate.wordpress.org/projects/wp-plugins/insert-php-code-snippet)

### מעוניינים בפיתוח?

[עיינו בקוד](https://plugins.trac.wordpress.org/browser/insert-php-code-snippet/),
ראו את הקוד ב-[SVN repository](https://plugins.svn.wordpress.org/insert-php-code-snippet/),
או הירשמו ל[לוג פיתוח](https://plugins.trac.wordpress.org/log/insert-php-code-snippet/)
באמצעות [RSS](https://plugins.trac.wordpress.org/log/insert-php-code-snippet/?limit=100&mode=stop_on_copy&format=rss).

## שינויים

#### 1.4.5

 * Improved snippet list UI and placement clarity
 * Added usage details for snippets used via shortcode
 * Minor bug fixes

#### 1.4.4

 * Added snippet description field
 * Fixed a security issue
 * Minor bug fixes and compatibility updates
 * CSS & JS files now versioned to fix caching

#### 1.4.3

 * Added a warning note that plugin data will be lost if the plugin is deleted
 * Updated redirects to use wp_safe_redirect() for improved security
 * Updated a few SQL queries to follow secure practices

#### 1.4.2

 * Added version check to trigger DB updates and clear cache on updates
 * Minor bug fixes and performance improvements

#### 1.4.1

 * Fixed image size issue reported
 * Updated snippet dropdown in editor to allow only shortcodes in Manual Placement
   mode
 * Fixed minor bugs and optimized performance

#### 1.4

 * Added new Snippet Placement Methods: Automatic, Execute on Demand, and Shortcode(
   Manual) for more flexible snippet placement options.
 * Added Snippet Placement filter on the Manage Snippets page
 * Improved compatibility with the latest WordPress versions
 * Fixed minor bugs and optimized performance.

#### 1.3.8

 * Added "Execute shortcodes in editors" setting for Elementor and other editor 
   compatibility
 * Updated about page with new premium feature details, including automatic placement
   locations

#### 1.3.7

 * Updated nonce verification for bulk actions to prevent CSRF attacks
 * Compatibility with WordPress 6.6.1

#### 1.3.6

 * Exception handling updated
 * Minor bugs fixed

#### 1.3.5

 * Patch security vulnerability
 * Compatibility with latest version of WordPress

#### 1.3.4

 * Minor bugs fixed
 * Compatibility with latest version of WordPress

#### 1.3.3

 * Minor bugs fixed
 * Option to send exception report to email

#### 1.3.2

 * Option to enable exception handling
 * Option to preview snippet
 * Database collation issue fixed
 * Minor bugs fixed

#### 1.3.1

 * Notice errors fixed

#### 1.3

 * Snippet selection support in classic editor block of Gutenberg
 * Support for Search Snippet by name
 * Navigation Improvements

#### 1.2.6

 * Support for Bulk Actions(activate,deactivate,delete)

#### 1.2.5

 * Added fix for output buffering issue

#### 1.2.4

 * Removed deprecated widget initializing function

#### 1.2.3

 * Option to enable auto insert of php opening tags added.

#### 1.2.2

 * Automatic detection and correction of php opening and closing tags in snippet
 * Updated nonces and validations
 * Premium version details and comparison added

#### 1.2.1

 * Nonces Added
 * A few bug fixes

#### 1.2

 * Compatibility with wordpress 4.3
 * Added options to sort snippets in admin area by id and title
 * Removed redirection after snippet edit

#### 1.1

 * Snippet chooser TinyMCE plugin modified
 * Compatibility with wordpress 3.9
 * A few bug fixes

#### 1.0

 * First official launch

## מטא

 *  גרסה: **1.4.5**
 *  Last updated **לפני 4 שבועות**
 *  Active installations **100,000+**
 *  Tested up to **6.9.4**
 *  שפה
 * [English (US)](https://wordpress.org/plugins/insert-php-code-snippet/)
 * Tags
 * [Add PHP](https://he.wordpress.org/plugins/tags/add-php/)[insert PHP](https://he.wordpress.org/plugins/tags/insert-php/)
 *  [תצוגה מתקדמת](https://he.wordpress.org/plugins/insert-php-code-snippet/advanced/)

## דרוגים

 4.9 out of 5 stars.

 *  [  670 5-star reviews     ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/?filter=5)
 *  [  10 4-star reviews     ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/?filter=4)
 *  [  1 3-star review     ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/?filter=3)
 *  [  2 2-star reviews     ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/?filter=2)
 *  [  16 1-star reviews     ](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/#new-post)

[הצג הכל](https://wordpress.org/support/plugin/insert-php-code-snippet/reviews/)

## תורמים

 *   [ f1logic ](https://profiles.wordpress.org/f1logic/)

## תמיכה

יש לך משהו לומר? זקוק לעזרה?

 [פורום תמיכה](https://wordpress.org/support/plugin/insert-php-code-snippet/)

## תרומה

האם ברצונך לקדם את התוסף הזה?

 [ לתרום לתוסף זה ](http://xyzscripts.com/donate/)