Try something like this:
if ( !function_exists('get_field') && $_REQUEST['action'] != 'activate' )
This will prevent your function being defined for the run where a plugin is actually being activated.
Related Posts:
- Best collection of code for your 'functions.php' file [closed]
- Disable plugin / plugin action via theme
- How do I call wp_get_current_user() in a plugin when plugins are loaded before pluggable.php?
- Shared functionality in plugins and themes
- Need to create a Theme demo site that features multiple themes
- Declare a function before plugin does on the theme functions.php file
- Editor access to plugin settings
- Override the core function locate_template
- Set WordPress Featured Image For All Post Slugs Matching Image File Name in Specified Directory
- Fatal error: Call to undefined function cmsms_theme_page_layout_scheme()
- All sites themes functions.php have been changed
- Overwrite category head title
- Proper way to use plugin functions in functions.php
- Need to replace Currency Shortforms
- How to make a dynamic css class whose name changes every visit to confuse scraper
- Set up functions to be overridden without using function_exists() by short-circuiting them?
- How to add custom function to pluggable.php
- Removing the custom_image_header from wp_head
- What is the most efficient way of adding additional functionaliy for admin only
- RSS feeds for specific topics
- Hide Plugin Custom Post Type Menu Link
- Securing langugae folder
- How can I make the search bar in my wordpress site search all of the pages rather than just the blog posts?
- Shows warning when enable “wp_gallery_custom_links” plugin with Themify Builder
- How can I add a custom checkbox / radio button on the admin theme options to display a CSS or other?
- How to Call Function From Separate WordPress Install on Same Server?
- Can’t get custom user meta to show in header
- overwrite a plugin function in functions.php
- Why nested REPLY not working in WP Comments?
- wordpress plugin is not activating from widget
- Theme my Login plugin, how to update fields
- Plugin Handle URL With Custom Theme
- Globally register styles but enqueue them selectively
- Edit Yoast SEO breadcrumbs output [closed]
- How to read individual user’s directory and display content to that specific user?
- Adding Shortcode to Text Widget
- Date calculations from 2 custom fields
- Guidelines / restrictions about advertising /donate begging unside wordpress plugins or themes
- Snippets: is it better to add them in functions.php or make site-specific plugins?
- Overriding functions in wordpress plugins
- Does WordPress validate inputs to all functions? (such as get_user_meta and insert_user_meta)
- Admin Theme customization
- Custom random quote widget breaks when used in multiple sidebars
- Hooking in to replace the Sidebar/Widget areas
- WSOD after upgrading to 3.1
- Using a function to change favorites listing
- Display post lists in 2nd paragraph
- How to debug error message: Cannot modify header information
- Using a post-signup hook to get user details
- How to enable specific plugin only based around shop manager role?
- How to change constants in WordPress wp-config.php programmatically?
- Restrict media upload size by format
- How to use a class from another plugin
- Override Plugin Script Fucnction in WordPress
- How to display custom sidebar in wordpress 5.5.2
- Check for security updates
- Calling plugin function inside custom plugin for onclick event
- Show function to super admin
- (FES EDD) New vendor submission page is blank
- There is any way to remove post-format filter? [closed]
- Plugin-generated pages use Not Found or Pages Archive templates?
- creating html reusable blocks via shortcodes
- Is there any kind of theme on WordPress to sell my own movies?
- Create custom registration form for WordPress Multisite
- get current date + 90 days and checking every day
- Child Pages Short Code plug-in and hover capabilities?
- Adding a new field to the address field type in gravity forms
- Classified ad website : which solutions to use? [closed]
- Replacing a plugin function with a custom renamed function doesn’t work
- How to create an input field, and base the output on spreadsheet data? [closed]
- Linux Permissions and Ownership for WordPress
- posts comments goes to trash
- Facebook Messager Plugin
- WordPress site periodically goes down
- Masonry images not working
- Nested shortcode functions accessing variable
- Advanced Custom Field DatePicker [closed]
- Calling an attribute from a plugin shortcode
- How to call WordPress function other files
- Homemade plugin while using Themify Ultra
- Customize permalink wordpress category id
- Conditional attributes and logic per product category
- Disqus deleted comments are syncing with wordpress but active comments do not
- Admin style for just one plugin in dashboard
- Why namespaces are rarely used in WordPress plugins?
- What will happen if i deactivate my visual composer plug in? [closed]
- Finding the URL to be used to check if plugin is installed with a theme
- Theme/Plugin installation through url on button click
- (Big issue) Blog is Getting Down Each day.. what should i do.?
- Custom wordpress Theme and Plugin repository
- WP Query. Is there a maximum size?
- How to remove custom post type and add category and post name
- WordPress 3.8.3. custom theme – sliders won’t load js/css files
- How can I position ShareThis buttons manually when using the plug-in? [closed]
- Grab WordPress Salt Data From URL
- How to require users to login when not logged in
- Ajax : Call undefined function plugin_function() … can’t call any plugin function
- WordPress get_avatar function not correct working
- Error when using plugin QuickCache with plugin Mobile Smart ? [closed]
- WordPress metaboxes – textfield suggestion automatically populated