Tag Info

Hot answers tagged

8

The JavaScript function wp_attempt_focus is causing this issue. The function fires shortly after page load, clears the form and focuses on it, forcing users to manually enter their login information. Chrome is filling in the username and password automatically, just milliseconds before the JS function clears the field. Chrome does not properly pick up the ...


5

This is a known bug As far as I'm concerned, you can easily fix it by replacing if ( SCRIPT_DEBUG ) { with if ( defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ) { That should suppress the error for now. When Wordpress is updated again, this error may be overwritten, but I believe it will be fixed in the next update. UPDATE Fixed at build 32482.


5

If you don't wish to modify your core wordpress files to fix the issue, you can simply add the missing definition into your wp.config.php file. Something like: define('SCRIPT_DEBUG', true); Would remove the error. There is already a WP_DEBUG definition in there already so I would suggest putting it close to that.


3

Yes, a plugin that does not properly clean up after itself can continue to affect your site even after deletion. It can leave stuff behind in the database, or make alterations to your .htaccess file, which is probably the case in your scenario. You might need to restore your .htaccess file - look here for help with that.


3

The error isn't actually caused by your PHP version (PHP 4 constructors won't be removed until PHP 7) - it's a warning produced by WordPress in preparation for this. Each repetition of the error represents a plugin using the outdated code. Until your plugins' authors update them, you can run the following shell command on a Linux system to find the old ...


3

You can use admin_notices hook http://codex.wordpress.org/Plugin_API/Action_Reference/admin_notices For example: function ravs_admin_notice() { ?> <div class="error"> <p><?php _e( 'Article with this title is not found!', 'my-text-domain' ); ?></p> </div> <?php } on ...


2

The output that you posted above is expected behaviour for $wpdb->print_error() if the following is true - You are running a single site, not multisite $wpdb->suppress_errors is set to false $wpdb->show_errors is set to false From the looks of your code, you meet all those conditions. Note also that, unless you have turned them off previously, ...


2

Upon successful login wp_signon() sets a cookie in the http response header. Hence it has to be called before any HTML output is sent to the browser. Otherwise the "headers already sent" error will occur. After a successfull login you should redirect your user. Otherwise the login information will not present when the page HTML is rendered. A very ...


2

First of all, never use query_posts. Rather use WP_Query to construct your custom query which is the prefered way You are also using the category_name parameter wrong. If you look at the WP_Query documentation, it states category_name (string) - use category slug (NOT name). Go and have a look at the examples given in the docomentation under the ...


2

This error: Fatal error: Call to a member function insert() on a non-object Means that $wpdb isn't instantiated so you are running your code too early or out of WordPress context-- for example, in an exterior PHP file accessed directly, which is what I suspect (Poorly conceived AJAX request perhaps?). As mentioned, the code has more formats that data ...


2

Try to disable the plugins via the database running this query in your MySQL: UPDATE wp_options SET option_value = 'a:0:{}' WHERE option_name = 'active_plugins'; Also, try to enable error debugging in your wp-config.php file adding this line: define( 'WP_DEBUG', true ); Also, could you paste a copy of your .htaccess file?


2

Xan is a georgian letter as I can find in Google, but it's not a valid Unicode Script for RegEx, you can find a list of the Unicode Scripts here: http://www.regular-expressions.info/unicode.html Maybe try using another one than Xan, maybe Georgian: preg_match( '/[\p{Georgian}]/u', $content, $results ); Let me know how that goes.


2

The notice is easy to set via the hook admin_notices. You can set on each page a message via this hook. function my_admin_notice() { ?> <div class="updated"> <p><?php _e( 'Updated!', 'my-text-domain' ); ?></p> </div> <?php } add_action( 'admin_notices', 'my_admin_notice' ); Ping this hook on your ...


2

Your problem is that you're using Reserved Terms. error is a reserved term, you can't use it. To get around this, you could intercept the request early, and do a redirect, changing the query parameters in the process. For example, handling a link get parameter: add_action( 'wp' , 'reserved_term_intercept' ); function reserved_term_intercept(){ global ...


1

There are couple issues I see with your code that are probably contributing to your overall problem. Try fix the issues below and see if you can move forward with it. Syntax error: // Syntax here would cause error $q = new WP_Query( array('posts_per_page' => 'posts_per_page,'post_type'=>array($post_type),'category_name'=>$category)); Fix to ...


1

EDIT I have rewritten your complete shortcode. I've tested the code from my original answer, and with your code combined, the output was a bit unexpected. Major modifications I've removed category and replaced it with a tax_query (see WP_Query). The reason is, a tax_query can be used for build-in categories and for custom taxonomies, and custom ...


1

You should use wp_enqueue_script to add the script. The documentation contains information about the function and how it should be used and some helpful examples. Basically, you will need to add something like this to the functions.php file: function myextension_enqueue_scripts() { wp_enqueue_script( 'myextension-angular', plugins_url( ...


1

The function is_wp_error checks if the given var is an instance of WP_Error class (soruce code as WP 4.2.2): function is_wp_error( $thing ) { return ( $thing instanceof WP_Error ); } As you can see, if the given variable is a instance of WP_Error class, the function returns true, even if the object is empty. Your $error variable is a WP_Error ...


1

I had a similar issue when the permissions on the upload dir were not allowing the upload, try that first. Take a look at the codex Changing_File_Permissions for more info. Alternatively, check that the uploads dir is owned by the same user (on the server) as Wordpress, it's also mentioned in the above link. For how to... please find someone with more ...


1

Insert this into your wp-config.php // Enable WP_DEBUG mode define('WP_DEBUG', true); // Enable Debug logging to the /wp-content/debug.log file define('WP_DEBUG_LOG', true); // Disable display of errors and warnings define('WP_DEBUG_DISPLAY', false); @ini_set('display_errors',0); Before /* That's all, stop editing! Happy blogging. */


1

There is problem with the "wordpress-seo" permission so please following steps. There are two way 1) Upload from the wp-admin Step 1 -> Change the "wordpress-seo" permission or rename the "wordpress-seo" plugin to another Step 2 -> If you have change the permission then just upgrade the plugin and if you have rename the plugin dir then you need to ...


1

I am not sure where you got that export code but I don't see the PRIMARY KEY defined as it should be. Take a look at the code from Core that creates the table: 87 CREATE TABLE $wpdb->commentmeta ( 88 meta_id bigint(20) unsigned NOT NULL auto_increment, 89 comment_id bigint(20) unsigned NOT NULL default '0', 90 meta_key varchar(255) default ...


1

EDIT: If you use $post in a function, you have to define it of course: function xyz(){ global $post; //Your code } Initial answer, might help others: It appears to me, you do not use it inside an action or if so, you use it to early. It should work inside the 'init' action. So you could do something like <?php add_action( 'init', ...


1

Create a new file names wp-config.php and paste all the code than enter your db credentials it will solve your wp-config issue. <?php /** * The base configurations of the WordPress. * * This file has the following configurations: MySQL settings, Table Prefix, * Secret Keys, WordPress Language, and ABSPATH. You can find more information * by visiting ...


1

You need to create wp-config.php file. This new file is copy of wp-config-sample.php find it in root directory. After creating this copy name it wp-config.php and set up database setting into it. Also give access permission to it. Let me know if above wording is not used to for you.


1

Textdomain Error The error message mean, that you haven't a textdomain. There is required for translation of this string. In the first error message is the problem the missing textdomain on the function _n_noop(). Right usage as example below. _n_noop( 'Security Release', 'Security Releases', 'your_textdomain' ); Text Domain Information about the ...


1

The root of the problem is that isset expects a variable to be passed to it. Also, I'm assuming that you expect the get_post_meta() to return a scalar value and not an array, so I added the third parameter set to true. // 3rd param: $single. Value of true means get scalar value, not an array. $ytlink = get_post_meta( get_the_ID(), ...


1

There is nothing like answering your own question. After more testing I have found that increasing the PHP memory_limit fixed the issue. Which would all make sense, the larger resolution of the image means more processing to compile the different sizes when uploading and saving the image. I increased it to 96M and problem gone.


1

First thing i see that needs to be changed is your assigining unchecked values to your input fields. Try wrapping isset round the variable before echoing, this will stop errors if they are not assigned or empty. Second thing as you have passed a post id to get_post_custom() you dont need the second array. function basin_manager_meta_options(){ global ...


1

The first issue is your hosting company fault. The underlying library that performs the authentication that you are actually connecting to wordpress.org is probably missing some related configuration to be able to complete correctly the authentication. The solution they gave you is not secure and while I don't believe anything bad will happen because of ...



Only top voted, non community-wiki answers of a minimum length are eligible