Title: adding php code to elementor
Last modified: December 23, 2017

---

# adding php code to elementor

 *  Resolved [jagguy2](https://wordpress.org/support/users/jagguy2/)
 * (@jagguy2)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/)
 * Hi,
 * I want to add php code to my pages built with elementor. I got the insert php
   plugin but in elementor it does not work with pages built with elementor.
    I 
   can add php to a page but when adding this page to elementor the php code doesnt
   run as it displays php code as text.
 * I read you need to add php code to a page and insert the shortcode of that page
   in an elementor widget but I couldnt find out what the shortcode is.
 * Thanks

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [benpines](https://wordpress.org/support/users/benpines/)
 * (@benpines)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/#post-9810418)
 * You cannot add PHP code to Elementor, since this would pose a security risk for
   websites. You can create shortcodes that run PHP and add the shortcode to Elementor.
 *  Thread Starter [jagguy2](https://wordpress.org/support/users/jagguy2/)
 * (@jagguy2)
 * [8 years, 5 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/#post-9811381)
 * sure, but how do you do this? where is an example?
 *  [karenmca](https://wordpress.org/support/users/karenmca/)
 * (@karenmca)
 * [8 years, 3 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/#post-9908527)
 * So where’s an example? I can’t find one specific to using php.
 *  [purbeckpixels](https://wordpress.org/support/users/purbeckpixels/)
 * (@purbeckpixels)
 * [8 years, 3 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/#post-9908811)
 * [Enhanced Text Widget](https://wordpress.org/plugins/enhanced-text-widget/) supports
   PHP (I’ve used it before with Elementor and it works fine). You could also try
   the [Insert PHP Code Snippet](https://wordpress.org/plugins/insert-php-code-snippet/)
   plugin.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘adding php code to elementor’ is closed to new replies.

 * ![](https://ps.w.org/elementor/assets/icon-256x256.gif?rev=3444228)
 * [Elementor Website Builder - more than just a page builder](https://wordpress.org/plugins/elementor/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/elementor/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/elementor/)
 * [Active Topics](https://wordpress.org/support/plugin/elementor/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/elementor/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/elementor/reviews/)

 * 4 replies
 * 4 participants
 * Last reply from: [purbeckpixels](https://wordpress.org/support/users/purbeckpixels/)
 * Last activity: [8 years, 3 months ago](https://wordpress.org/support/topic/adding-php-code-to-elementor/#post-9908811)
 * Status: resolved