add the post as canonical for attachment page wordpress

the attachment page should have canonical added to the main post on attachment page (image.php) I currently have (automatically added by All in One Seo Pack): <link rel="canonical" href="https://example.com/main-post/image-name" /> And I want to change it to point to the post (where this image is attached) <link rel="canonical" href="https://example.com/main-post" /> You can ignore All in One Seo Pack if that is difficutl to change, and maybe simple provide a way to add the canonical to the main post.
Category: Web

Remove All in One Pack from the admin bar

Hello I want to remove All in One Pack from the admin bar. I can remove anything else but it. I have already removed other things like update from the admin bar using this method Get the menu's id by this code: // Debug admin bar menu and submen if (!function_exists('aldous_debug_admin_menus')): function aldous_debug_admin_menus() { global $submenu, $wp_admin_bar, $pagenow; if ( current_user_can('manage_options') ) { // ONLY DO THIS FOR ADMIN if( $pagenow == 'index.php' ) { // PRINTS ON DASHBOARD echo …
Category: Web

Is the SEO plugin necessary?

I want to understand how wordpress is structured in the first place with regard to search engine friendliness. Isn't it set up for SEO by default? Is the SEO plugin necessary then? and to what extent does post name in the url make a difference as against the standard numerical format of wordpress urls?
Category: Web

Adding Plugin-specific Fields with wp_insert_post()?

(Moderator's note: The original title was "wp_insert_post() and plugins") I use wp_insert_post() like this: $my_post = array( 'post_title' => 'title', 'post_content' => $post, 'post_status' => 'publish', 'post_author' => 1, 'post_date' => date('Y-m-d H:i:s', $oldtime), 'post_category' => array(3,4) ); wp_insert_post( $my_post ); Everything works fine, but I want to use plugins like "All in One SEO Pack" I can't figure out how to save their custom fields. I tried this but it did not work: $my_post = array( 'post_title' => 'title', …
Category: Web

I have a problem with Home Page title

I am using WordPress and "All in one SEO pack" plugin. I set up the title, descriptions, and keywords, and everything is working nice on site. Then I accidentally looked for my site on Google. I enter my domain in search and when I found my site, I was surprised that my title is not the same as on my site. It's a totally different title, but the description is good. I try some changes but it's not showing in …
Category: Web

How to restrict an admin page, if the user is not superadmin?

I use the All In One Seo Pack on my multisite, but this plugin have admin pages, what is not fall under the rule what restrict the plugin pages from my users, so I using the remove_cap( $cap ); about 'edit_plugins', 'install_plugins', 'upload_plugins', but this not solving my issue. I want restrict this pages on my network's subsites: wp-admin/admin.php?page=all-in-one-seo-pack%2Faioseop_class.php wp-admin/admin.php?page=all-in-one-seo-pack%2Fmodules%2Faioseop_performance.php wp-admin/admin.php?page=all-in-one-seo-pack%2Fmodules%2Faioseop_sitemap.php
Category: Web

Custom meta Title for custom post type archive from page

I've set up some custom post types, and created custom archives, eg in the following format: archive-books.php (With a template name of "Books Template"). I then have a page (/books/) created in wordpress, with the above archive-books.php assigned as the template. How would I get the the meta title (wp_title) to be the title that I set on the page (/books/)? - At the moment it's just showing "books | sitename". Even if I change the All in One SEO …
Category: Web

Two description meta tags All in One SEO WordPress

After installed All in one SEO plugin my home page has two descriptions. One by WordPress itself and one by All in one SEO plugin. Is there a simple way to remove WordPress one? Please reconsider closing post as off-topic. Cos already done twice: https://webmasters.stackexchange.com/questions/2475/two-description-meta-tags-all-in-one-seo-wordpress https://stackoverflow.com/questions/3549769/two-description-meta-tags-all-in-one-seo-wordpress-closed
Category: Web

Should a SEO plugin be necessary?

I'm using the All in One SEO plugin for my site. The extra fields and options it supplies seem like they could be handled via a theme, possibly negating the use for a plugin. Should SEO considerations be handled by a theme, rather than delegating the work to a separate plugin? It could reduce maintenance issues, takes up less space, and be more integrated.
Category: Web

My post titles is getting mashed up with my blog title

I installed the all in one seo pack plugin and after enabling it my post titles get "stuck" with my blog title without a space in the title. As you can see the post title is: ******.blogg.no And my blog title is: Sp**set Blogg The title is now *******.blogg.noSp**set Blogg, I can't figure out how I can get these to separated. My all in one seo pack settings is%post_title% on the posts.
Category: Web

Doubled titles when using All in One SEO with custom template

I created a separate template, attachment.php, for displaying image attachments. It's relatively simple; basically a stripped down version of single.php. Everything is working great except that when I have the All in One SEO plugin enabled (and set to rewrite titles), the titles on those attachment pages are being doubled. For example, this attachment's title should be "11 hours of MacBook Air battery life", but the title tag is being rendered as "11 hours of MacBook Air battery life 11 …
Category: Web

All in One SEO plugin stopped working after update

I'm using the "All in One SEO" plugin. I never had issues with it. It worked perfectly fine. Recently, however, I noticed that it doesn't generate the information (title, description) anymore. Especially the SEO-friendly description I enter in my posts in the field that the plugin provides is totally being ignored by search engines, Facebook, Google+. Instead just the first few sentences of each post appear. As I haven't changed any settings recently, but remember that I automatically updated Wordpress …
Category: Web

How to remove duplicate blog title

My blog is www.theprinterdepo.com/blog. The blog title its in the beginning and at the end, which looks bad for seo efforts, I have a pluggin called ALL In one SEO. Which puts the title of the blog at the end, which is fine. But I cant find how to remove it from the start of the meta title. thank you I suppose this is the code you need: <title><?php wp_title('|', true, 'left'); ?></title>
Category: Web

two meta tags with all in one seo

I use womanish theme and I install the all in one seo pack , but I see two meta tags for keyword and description in source code,I can't find the related code in header.php or top.php, How can I fix that? I can not resovle my problem, Is it will be a bad impact in seo?
Category: Web

Error activating certain plugins

When I try to activate All-In-One SEO Pack or ANY (I've tried all by now!) caching plugin, the page goes blank - i.e the content of the page empty, except the WordPress bar on the top and the toolbar on the left. No error is displayed. What is wrong? All other plugins are activated and work just fine! Please help!
Category: Web

All in One Seo and Permalinks

I'm using All in One seo and for the Post Title Format option I have it as: %post_title% kewyord1 keyword2 etc keyword1, keyword2 being my chosen keywords for my site Also, in Permalinks, I have it as /%postname%/ so that the post name shows up in the shortlink/url So with these configurations, if I make a post in with 'Books' in the title it will look like this: Books keyword1 keyword2 etc But the shortlink, or the actual url of …
Category: Web

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.