We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

How to fix Errors in Live Preview

How Do I?

Okapi Creative's avatar
Okapi Creative
382 posts
2 years ago
Okapi Creative's avatar Okapi Creative

Trying to use Preview on an entry in the CP and get the following errors:

Notice Undefined variable: uri ee/ExpressionEngine/Service/LivePreview/LivePreview.php, line 185

Severity: E_NOTICE Warning Cannot modify header information - headers already sent by (output started at ee/legacy/core/Exceptions.php:120) ee/ExpressionEngine/Boot/boot.common.php, line 475

Any idea what causes these or a possible fix?

       
Andy McCormick's avatar
Andy McCormick
322 posts
2 years ago
Andy McCormick's avatar Andy McCormick

Can you post what version of EE you are on, and the template code for your live Preview template?


Upcoming EEConf Events:

  • March EE Community Meetup - March 22, 2023
  • EEConf Spring Conference - May 10, 2023
  • EEConf Fall Summit

Find out more about EEConf and our events throughout the year at www.eeconf.com

       
jiwolog's avatar
jiwolog
1 posts
one year ago
jiwolog's avatar jiwolog

Usually, this error occurs when the variable $uri is referenced but either not initialized or not properly supplied to the function/class method.

Examine the code in LivePreview.php around line 185. Make sure that $uri is set appropriately if it is supposed to be provided into a function or method. Make sure you’re extracting or changing the value appropriately before attempting to use $uri if it’s coming from a request or URL. Make sure the necessary configuration or variables are set before the preview function is called, as it’s also conceivable that the live preview capability isn’t being initialized correctly.

Since this problem might not show up in a new, unmodified setup, you could wish to check for any custom customizations or plugins that are interfering with the live preview process. Check out our site for more information. geometry dash lite is a free version of the popular rhythm-based platformer Geometry Dash, created by Robert Topala and published by RobTop Games.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.