Resolving Performance Issues and Admin-AJAX Calls in PixelYourSite
Content
Many users of the 'PixelYourSite – Your smart PIXEL (TAG) & API Manager' plugin encounter performance issues related to AJAX calls and large log files. This guide explains the common causes and provides steps to resolve them, helping you maintain a fast, efficient website.
Common Performance Issues and Their Causes
Based on community reports, the most frequent performance-related problems are:
- Slow admin-ajax.php calls: The plugin makes calls to
admin-ajax.phpfor actions likepys_get_gdpr_filters_valuesorpys_api_event, which can sometimes take several seconds to complete and slow down page loads. - Large log files: Enabling features like Conversion API debugging or Meta API logs can generate massive files (e.g., 280MB, 7GB), consuming server disk space.
- Persistent admin notifications: Promotional messages or warnings can be difficult to dismiss for some users due to plugin conflicts.
- Database bloat: Certain features, like EDD reports or old logging systems, can create large amounts of data in the
wp_optionstable.
These issues often stem from necessary plugin functions that interact with cache systems and consent management tools. However, they can sometimes become overly aggressive or fail to be properly controlled by their respective settings.
How to Troubleshoot and Resolve These Issues
1. Managing AJAX Calls
AJAX calls are used to bypass caching for dynamic data like event IDs and GDPR consent status. If they are causing performance problems, you have a few options:
- Locate the AJAX Settings: The primary setting to control AJAX behavior for the Conversion API is located at the bottom of the plugin's main settings page. A separate setting, "Enable AJAX filter values update," is found in the Consent tab. Ensure both are configured to your needs.
- Test Before Disabling: The 'PixelYourSite' team strongly advises testing your site's functionality in an incognito or private browser window after disabling AJAX. This checks if tracking and consent still work correctly with your cache plugin active. If everything works, you can safely ignore the warning notification about enabling AJAX.
- Understand the Trade-off: Disabling AJAX can improve performance but may cause issues with cached pages, such as duplicate event IDs or failure to respect user consent choices.
2. Controlling Log File Sizes
Large debug.log or API log files are almost always caused by logging being left enabled.
- Disable Logging: Logging should be kept OFF by default. You can manage this from the dedicated "Logs" page, which is linked in the plugin's admin menu.
- Delete Existing Logs: It is safe to delete large log files directly from your server via FTP or your hosting file manager. You can also clear them from the plugin's Logs page. For very large database logs (e.g., in the
aepc_logoption), you can safely delete the value via phpMyAdmin if the plugin's clear function fails.
3. Handling Admin Notifications
The plugin displays admin notifications for important announcements and tips.
- Dismiss Notifications: Most notifications can be dismissed by clicking a close ('X') button or a "Don't show me more tips" link.
- Plugin Conflicts: If these buttons do not work, it is typically due to a JavaScript conflict with another plugin or your theme. To troubleshoot, check your browser's console for errors and try temporarily disabling other plugins to identify the culprit.
4. Cleaning Database Data
If you enabled a feature like "EDD Reports" by mistake, you can deactivate it to stop data collection. For old data stored in the database (e.g., in options like pys_just_login or aepc_log), it is generally safe to remove the values via phpMyAdmin as they are typically used for logging and not critical for the plugin's core operation.
Conclusion
Performance issues with 'PixelYourSite' often revolve around balancing functionality with resource usage. The key steps are to ensure logging is disabled after debugging, carefully manage AJAX settings based on your caching needs, and dismiss or troubleshoot admin notifications. By following these guidelines, you can optimize the plugin for better website performance.
Related Support Threads Support
-
Disabling AJAX filter values update in Consent tabhttps://wordpress.org/support/topic/disabling-ajax-filter-values-update-in-consent-tab/
-
Ajax Disabled, but Still Fires with a 3s Pagespeed Timehttps://wordpress.org/support/topic/ajax-disabled-but-still-fires-with-a-3s-pagespeed-time/
-
Heavy debug.log filehttps://wordpress.org/support/topic/heavy-debug-log-file/
-
AJAX Calls still appears even though they are turned offhttps://wordpress.org/support/topic/ajax-calls-still-appears-even-though-they-are-turned-off/
-
AJAX filter values update not workinghttps://wordpress.org/support/topic/ajax-filter-values-update-not-working/
-
Notifications in admin areahttps://wordpress.org/support/topic/notifications-in-admin-area/
-
hide dashboard notificationhttps://wordpress.org/support/topic/hide-dashboard-notification-2/
-
pys_get_gdpr_filters_values making a lot of admin-ajax requestshttps://wordpress.org/support/topic/pys_get_gdpr_filters_values-making-a-lot-of-admin-ajax-requests/
-
Notifications in admin areahttps://wordpress.org/support/topic/notifications-in-admin-area-2/
-
Ajax calls won’t stop, no matter the confighttps://wordpress.org/support/topic/ajax-calls-wont-stop-no-matter-the-config/
-
Remove console.log “PixelYourSite PRO version” from every pagehttps://wordpress.org/support/topic/remove-console-log-pixelyoursite-pro-version-from-every-page/
-
pys_just_login data is big on databasehttps://wordpress.org/support/topic/pys_just_login-data-is-big-on-database/
-
Remove the noice for Ajaxhttps://wordpress.org/support/topic/remove-the-noice-for-ajax/
-
Activated EDD reports by mistakehttps://wordpress.org/support/topic/activated-edd-reports-by-mistake/
-
API logs are creating a large filehttps://wordpress.org/support/topic/meta-api-logs-are-creating-large-file-sizes/
-
aepc_logs enormoushttps://wordpress.org/support/topic/aepc_logs-enormous/