Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [title]

Title is the main label on a piece of information. In WP the term is mainly used to label a whole html page, a post, a widget or an attachment.

0
votes
0answers
17 views

Custom archive paged head title

My website is in hebrew and when im in a paged archive the title is "archive title" page 2 of 4. How can i add the title only in archives that are in a page 2 or higher? I am using Yoast SEO. And its ...
0
votes
0answers
20 views

How to display custom seo title before the loop?

So I've optimized one of my archive page title to this add_filter('wpseo_title', 'new_filter_title'); function new_filter_title($title) { if ( is_page('1637') && $...
0
votes
1answer
24 views

remove the title attribute from links [closed]

I'm looking for a way to remove the title attribute from links. There is a old plugin but it breaks the site. The title I would like to remove is in the sidebar widget. Thats the code of the widget ...
0
votes
0answers
18 views

How can I change the style and size of font of Blog Title?

I want to change the font size of my blog title and also make it bold and change the style, But there is no option when I select the title of blog page. How can I change that ?
0
votes
1answer
58 views

Change meta-box title- “LearnDash Quiz Settings” to “Quiz Settings”

I want to change a meta-box title on the create question page from- "LearnDash Quiz Settings" to "Quiz Settings" on create question page. I have seen a few posts that explain changing custom posts ...
1
vote
1answer
18 views

Is possible add icon in title posts only in specific tag?

I want to add an icon in title posts only in posts with specific tag. Is this possible? I've already tried these codes, but they didn't solve my problem: Approach #1 if (is_tag('162')) { ...
0
votes
0answers
11 views

Change <title> tag Based on Current H1 Title in Archive Page (Using Yoast)

So basically I have custom code for my archive title, which goes like this: <?php // get the currently queried taxonomy term, for use later in the template file $kendaraan = get_query_var('...
0
votes
1answer
18 views

Set category page title in custom theme [closed]

I'm new in wordpress. I am using one custom theme and install in wordpress. I want to change category page title and remove "Category:" prefix from title. How can I manage it from admin ? I don't ...
0
votes
0answers
15 views

Specify/change IMG title when uplaoding image through custom admin page

I created a custom admin page where a registered user can upload an article including an img and two pdfs. Now I want to change the meta title of the pdf when uploading. My code: if(isset($...
0
votes
1answer
18 views

What is the wordpress page title php code?

I have a header file in WordPress theme which always shows site title after the creation of a new page because of code <?php echo esc_html( get_bloginfo( 'name' ) ); ?> but I want it to replace ...
0
votes
0answers
9 views

Remove Duplicate Title Tags for Automatic Created URL

When I embed the video to my website, Wordpress will automatically generate URL for me. However, these URLs are have the same title tags. How can I make changes to it? e.g. https://spotworks.com.sg/...
0
votes
1answer
20 views

Please I want to prefix my WP posts title according to each category

What i mean is that. My categories are: Music. Video Etc... So i want post title per category to be like this. Post in music = should be "Download Music: wp_title()" Post in video = should be "...
0
votes
0answers
27 views

Auto generate post title from two CPT meta fileds

Dear code experts on the forum, I really need urgent help for my website, I use CPT named ''auftragerstellen'', and do not fill in the post title(since the user could not fill in the title on the ...
1
vote
0answers
21 views

WP Query Args - Title or Taxonomy Value

How do I query by tax_value or title? I have $args = array( '_meta_or_title' => sanitize_text_field(preg_replace('/%20/', '+', $query[1])), 'posts_per_page' => 100, 'post_type' =&...
0
votes
0answers
22 views

How to add each letter, entity, special character from post title to array

I try to add each letter, entity, special character from post title to array but quote symbols not working. I use this function in the loop and single post page. Entities are in the numeric HTML ...
0
votes
0answers
32 views

Unable to replace custom post_type slug by the publish_post. But the save_post is working properly (wp_update_post)

I would like to update the_title when saving the events every time. And the slug when publish new events only. <?php function set_title_on_save( $post_id ) { $post_type = get_post_type($...
0
votes
1answer
19 views

How to Add or Change Post Title

How to add post titles with new titles via sql? example post title now "beddu". i want to adding/ change "Add beddu" thank before
1
vote
1answer
22 views

CPT Post Title Permalink: Replace “@” (or all special characters) with dash “-” instead of just removing

I have Custom Post Type "Email", where the Post Title is always going to be an email address, ie: example@domain.com The problem I am having is the "@" is being removed in the permalink: ../...
0
votes
1answer
63 views

How to get current page title inside a page itself in a shortcode and in page content

When i add the <?php the_title(); ?> to a page template file it works and is able to pull the page title inside html tags however if i wanted to add <?php the_title(); ?> to a ...
1
vote
1answer
33 views

How to Change The Title in WordPress For SEO

My concern is when I search for that company I see what is shown in the image. Instead of Home, I require it to show a custom title that is good for SEO. What is the best way to fix this? Please ...
0
votes
2answers
27 views

How to get current page title inside a page's template

I am trying to get the page title to show up inside various h1, h2 and p tags that i have part of the page template - so that when the template is applied to a page it will make the current page's ...
0
votes
0answers
21 views

Add id attribute to h1 element of wordpress post

The default rendering of the h1 element of a wordpress post looks like this: <h1 class="entry-title"> XYZ </h1> I would like to add the id attribute to the h1 element with the value of ...
0
votes
1answer
20 views

Get youtube link title in post title

If my post title is https://www.youtube.com/watch?v=PJmMiZH3Q6I I want it to be converted to original video title which is "Ras Cricket - Fyah" Is there a way without API stuff cause it seems hard.
0
votes
2answers
31 views

How to echo all the_title() without text after last “-”

I am trying to do something but I have problem... I wont show the list of my post, but from all titles I want remove text after last "-" (dash) My list of posts: My experience - this boy - ...
0
votes
1answer
166 views

woocommerce related product title length

Can't believe there is no standard workaround to limit product title for the related product section. So far, I managed to limit product title for all other pages by using Woo Title Limit plugin. By ...
0
votes
0answers
29 views

adding title=“” Anchor text to Woocommerce Product links

I have been advised, to help with SEO it is advisable to add Anchor Text titles to the website internal links. I have done this with my custom links when linking between pages. however for the ...
0
votes
0answers
22 views

How to change the title of a woocommerce category / taxonomy page when a filter is applied

I am looking for a solution to come up with a new title for a category / taxonomy page when a filter is applied. Let's assume we have a webshop offering T-Shirts and we have a product attribute called ...
7
votes
3answers
503 views

Apply the_title() filter in post & page title, but not in menu title

I use the following code to change the title of WordPress posts and pages. But it changes nav menu item titles too, which I want to avoid. I want to change the title of posts and pages in: home page, ...
0
votes
1answer
70 views

How to make the first letter of a post title uppercase, in a plugin?

I'm making a plugin that makes the first letter of the first word in a post title uppercase, if it was lowercase. I'm a beginner, so it's simple, but even so I struggle! The plugin can be activated ...
0
votes
0answers
26 views

Set page title in WordPress with PHP

I know this question has been asked thousands of times before, but I have attempted a lots of these solutions without any success. Attempted solutions, among others (added to the template page) ...
1
vote
1answer
28 views

Adding a title below the logo

I need to add a site title as a text below the logo for a site. The title should be <h2> tag. The theme allows either image or text, but not both.
0
votes
1answer
29 views

Change meta data of pdf file

I've noticed recently that pdf files provided by client have got indexed with weird and random title tags when searched for in google (site:mysite.com/path-to-file.pdf). Now I've tried to change it ...
0
votes
1answer
1k views

Remove “Category Archives: title” at the top of a category page [duplicate]

I created a category page that's linked to the main menu. It posts the categories fine, but it has the text "Category Archives:________" at the top of the page. Does anyone know to remove this. I'm ...
0
votes
2answers
37 views

Page Title Dependant On Input?

We recently implemented a stock quote system, where a user can enter a stock symbol and it will return all sorts of financial values. I have a template made up that displays the financial widgets, ...
0
votes
1answer
27 views

how to costume title single page

how to costume title single page on wordpress , for example in this picture , i want to change/add text "Theme Preview" ?
0
votes
0answers
85 views

Reorder title tag and description tag with wpseo_title and wpseo_metadesc

I'm trying to change the order of the title tag and description tag (CMS Wordpress, plugin Yoast SEO). Now in the code of the page it looks like this: <title>something ...</title> <...
2
votes
2answers
52 views

Add Category name to Post Title (h1)

How to add Category name to post title (H1)? “PostTitle + CategoryName”? My h1 post title code: <?php the_title( '<h1 class="entry-title">', '</h1>' ); ?>
0
votes
1answer
194 views

How come I get internal server error even with try catch for get_the_title in functions.php?

I'm relatively new to PHP & wordpress but not to programming. I wanted to have a title relative to the $post title, so I created the following filter and added it to functions.php: add_filter('...
0
votes
2answers
231 views

Can't change the title tag with wp_title filter

I'm using a theme child of Ultra Theme. This theme is using this : add_theme_support( 'title-tag' ); I'd like to customize the title tag of all posts & pages, here is my code : add_filter( '...
1
vote
1answer
87 views

Change sidebar headers from H1?

My theme uses H1 tags without much thought, including the site name at the top of each page and each of the sidebar menu titles. I checked the sidebar.php file in my themes folder, but there is no ...
0
votes
1answer
47 views

How can I add a title to this 'maintenance mode' function?

I use the function below to manually trigger temporary 'maintenance mode'. function maintenance_mode(){ if ( !current_user_can( 'edit_themes' ) || !is_user_logged_in() ){ wp_die('<img src="/...
0
votes
0answers
11 views

Add warning error if post title exists

I see code in this https://wordpress.stackexchange.com/a/250623/144156, it working. But i want to add echo a warning text error like "Enter title before publish" if empty title, and a text "A post ...
1
vote
2answers
50 views

How to Change Title Attribute to be different from Page title

My Wordpress Site (PeterKellner.net)'s home page is a page titled "Who is Peter Kellner". The browser tab shows that and I want it to just say peterkellner.net. How can I make that happen without ...
0
votes
0answers
856 views

How to remove “archive” in title?

How to remove "archive" in title? The category page is "technology", I have no idea why there is a word "archive" behind it.
0
votes
1answer
26 views

Does changing a post title of a published post automatically change permalink?

In what I’ve seen and what i’ve read, changing a title to a published post won’t change the permalink. I researched again this morning and found nothing to contradict that. However, a client changed ...
0
votes
0answers
18 views

the_title() filter is appending string length to title

My title filter appends the string length to the changed title. Why is it doing this? How can I remove it? My goal: Change the header title only in the header section. My filter: function ...
0
votes
0answers
19 views

How can I remove an unwanted character from the main page's title?

I'm working on this website: http://mel-mary-blog.fr/ Since the girls creating all the articles wanted a better SEO, I installed Yaost and did all the configuration I could without paying for the ...
0
votes
2answers
173 views

How do I show the post title if an advanced custom field hasn't been used?

I've got an archive page for to display custom post types. Within the WP_Query that displays the custom posts types I want to display an ACF (Advanced Custom Field) or, if the user hasn't filled out ...
0
votes
1answer
30 views

Permalink and ACF field

I'm trying to get the thumbnail and title from permalink outside the main loop using ACF field: <?php $post_id = get_field('1_main_post'); if( $post_id ): ?> <a href="<?...
0
votes
1answer
46 views

How to search titles/artist/album within a playlist, and only lists the results that match?

I am creating a simple audio WordPress theme, and have a playlist being rendered in the front page using short-code [playlist ids="29,30,31,32,33,34]". How to list only the songs with title (or artist)...