RSS feed does not validate on wordpress - wordpress

I have an error message when I click on my site's rss feed url (both from feedburner and the original atom feed):
"This page contains the following errors:
error on line 2 at column 6: XML declaration allowed only at the start of the document
Below is a rendering of the page up to the first error."
I Have check with The rss feed validator and this is what I got:
http://validator.w3.org/feed/check.cgi?url=http%3A%2F%2Ffeeds.feedburner.com%2FNoCamels
I tried everything they suggested (also restarted the plugins) - but nothing worked.
PLEASE, I need your help!
Yuval

You simply have a blank line outside php tags in your wordpress files.
You should check and remove blank lines in :
wp-config.php
functions.php of your theme
*.php in your plugins
...etc
Take a look here :
http://www.quickonlinetips.com/archives/2009/05/wordpress-feed-xml-parsing-errors/

I had the same problem. The culprit was the wp-trackback.php. Blank space at the bottom. I cleared the blank space and voila. RSS is working now.

I have also this question. I solved from error on line 2 at column 6
You simply have a blank line outside php tags in your WordPress files.
You should check and remove blank lines in :
wp-config.php
functions.php of your theme
*.php in your plugins
...etc
Take a look here

Related

wordpress site showing warrning in some section

my wordpress site is running ok but in some section this warning is shown
Warning: Parameter 2 to gdlr_core_page_builder::search_page_builder() expected to be a reference, value given in C:\xampp\htdocs\wordpress\wp-includes\class-wp-hook.php on line 287
wordpress ver:5.4.1
i deactive all plugin and active one by one and found when i deactive one of the plugin (Goodlayers Core
) not showning error anymore but all element of site is disappear because it's core of theme it seems.
The error describe itself.
From somewhere the 2nd parameter of the function gdlr_core_page_builder::search_page_builder() is passed as value which should be a reference.
The error showing in file class-wp-hook.php on line 287 because of there is some hook is added into the above function.
You can contact that plugin author who will fix this issue if it is exist and release that plugin update.
This is a plugin issue. However, you can simply disable the displayed warning by adding the below lines of code in wp-config.php file.
Locate your file under cPanel FileManager:
/home1/yoursitename/public_html/wp-config.php
Add the below lines of code to hide the displayed warning:
ini_set('display_errors', 'Off');
ini_set('error_reporting',E_ALL);
define( 'WP_DEBUG', false );
define( 'WP_DEBUG_DISPLAY', false );
Had the same issue, fixed by removing vars passed by reference (&$) on the file /wp-content/plugins/goodlayers-core/framework/function/page-builder.php:
open the file
search for &$, replace by $
save, refresh website (clear cache if needed), error is gone

How do I include a partial from a directory above a wordpress theme directory?

I have 3 themes set up right now and I need them all to inherit partials from the same source in order to update all three themes at the exact same time when I change any of those partials.
I'm seeing that
include("../../../includes/vital/partial.php");
doesn't work from within single.php or any other other theme template file. The error I get is:
Warning: include(): Failed opening '../../../includes/vital/partial.php' for inclusion (include_path='.:/usr/local/Cellar/php56/5.6.8/lib/php') in /Users/insertusername/Documents/Code/Projects/wordpress/wordpress-1/wp-content/themes/flowerz-mobile/single.php on line 7
How can I make this work?
Thanks!
Since Wordpress loads all based on the main index.php the code below worked for me in every theme.
include("includes/vital/partial.php");
that`s right, without any ../ at the begining.

Want to set wordpress website's page title

In My wordpress website's page titles are start with >> symbol I want to remove that >> symbol so please help me..
and I'm using wordpress-seo plugin after that this problem is occuring
You have to modify your theme to do that.
Most likely you have to modify the header.php file using the wordpress theme editor.
Find the line where wp_title is called and call it with an empty string as first parameter.
When wp_title is called without any parameters it adds the leading » (») by default.
You can also trim the result of wp_title to avoid leading and trailing whitepspace.
Take a look at the following links too:
http://www.onlinenerd24.de/2008/09/29/remove-the-from-your-wordpress-title/
http://cuongdang.info/how-to-remove-the-arrows-%C2%BB-from-wordpress-titles.html
http://codex.wordpress.org/Function_Reference/wp_title (take a look at the $sep param)

Wordpress goes blank after publishing new content?

So out of no where after clicking the publish button the page just goes blank...
The url at the top is:
http://www.brightboxstudios.com/sociabulls/wp-admin/post.php
What's good news is it still posts the content :)
Not great at coding so details rock :)
I was getting same error, when I update the site content and press update it goes to /wp-admin/post.php and this appears as blank page.
It is solved by:
I removed all the spaces at the end of functions.php file, I had included a widget and there were some spaces in between older content and new widget function, when I removed the spaces everything is working fine.
if that don't work then
- go into wp-config.php and find this "define('WP_DEBUG', false);"
change its value, if it is flase, make it true or if it is true change it to false.
And everything must work Good.
Thanks
A blank page usually means Apache failed. Check your error logs. You'll probably find a line that starts with:
PHP Fatal error:
You can also display your errors on the screen instead of looking at the log.
There will be many reasons for blank page, you have not mention version for wp, php etc.
To solve wordpress blank page issue follow the steps
disable all plugin and try (if there is an error in plugins then enable 1 by 1)
switch to default theme and try (if there is an error in theme)
rename .htaccess and param-link to default (page/post id)

how to activate wordpress plugins internally?

I am creating a small utility which will help to rebuild install.php of WordPress.
What I want to achieve is, when user will install WordPress with this customized install.php, he'll get some plugins already activated.
I tried to put these lines at the end of install.php file
require_once('path...\wordpress\wp-includes\plugin.php');
activate_plugin('hello.php');
that activates Hello Dolly plugin but shows error 'invalid datatype for second argument on line 310' for plugin.php
Also, if I try plugins which are inside a folder, for example
require_once('path...\wordpress\wp-includes\plugin.php');
activate_plugin('plugin-folder\file.php');
its not getting activated.
[i've tried different combinations for sending arguments, echoing arguments in plugin.php etc. but activate_plugin() does receive correct argument. ]
Consider that plugins are already copied in wp-content/plugins directory.
Whats wrong? Is there any different way to achieve this?
Thanks
Instead of including plugin.php file, include the wp-load.php file
require_once('path...\wordpress\wpload.php');
wpload.php will automatically include all the file in the correct order, which should solve your issue.
Atlast I came up with a new activate_plugin function that I added to that file. Problem in old function is the check for active plugins. At first since there is no active plugin, it was returning null value, showing the error. I removed that for my use.
why we dont see errors when using from wordpress dashboard ? wordpress hides them.
Thanks anyway..

Resources