• Resolved toondg

    (@toondg)


    Hi,

    I created a custom post type, and the plural version has a ‘ character. In the main menu option and title this is displayed correctly “auto’s”, but in the submenu and a number of other places, the ‘ character is html encoded “auto's”.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Honestly not sure there’s going to be anything CPTUI can do with that part, as those would be spots handled by WordPress core. If after you registered the post type with the apostrophe in the label, and our UI showed it with the HTML encoding, then we could handle that part. However when getting shown in the UI overall, that’s after we’ve done our work, so I don’t really have a great answer for this.

    Thread Starter toondg

    (@toondg)

    The default “Pages” menu (Pagina’s in Dutch), does show the ‘ correctly everywhere, so I thought that the error might be in CPTUI. Or maybe CPTUI does send the names html encoded, and WordPress core does html encode them again in some places.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Can you paste me your blob of content from the Tools menu and the post type tab? That’ll allow me to review the settings and see if anything looks a little amiss.

    Thread Starter toondg

    (@toondg)

    Sure, here it is.
    Thank you for taking a look.

    {"car":{"name":"car","label":"Auto's","singular_label":"Auto","description":"","public":"true","publicly_queryable":"true","show_ui":"true","show_in_nav_menus":"true","delete_with_user":"false","show_in_rest":"true","rest_base":"","rest_controller_class":"","rest_namespace":"","has_archive":"false","has_archive_string":"","exclude_from_search":"false","capability_type":"post","hierarchical":"false","can_export":"true","rewrite":"true","rewrite_slug":"car","rewrite_withfront":"true","query_var":"true","query_var_slug":"","menu_position":"30","show_in_menu":"true","show_in_menu_string":"","menu_icon":"dashicons-car","register_meta_box_cb":null,"supports":["title","editor","thumbnail","excerpt"],"taxonomies":[],"labels":{"menu_name":"Auto's","all_items":"Alle Auto's","add_new":"Nieuwe toevoegen","add_new_item":"Nieuwe Auto toevoegen","edit_item":"Bewerk Auto","new_item":"Nieuw Auto","view_item":"Bekijk Auto","view_items":"Bekijk Auto's","search_items":"Zoek Auto's","not_found":"Geen Auto's gevonden","not_found_in_trash":"Geen Auto's gevonden in prullenbak","parent":"Hoofd Auto:","featured_image":"Uitgelichte afbeelding voor deze Auto","set_featured_image":"Uitgelichte afbeelding instellen voor deze Auto","remove_featured_image":"Uitgelichte afbeelding voor deze Auto verwijderen","use_featured_image":"Gebruiken als uitgelichte afbeelding voor deze Auto","archives":"Auto archieven","insert_into_item":"Invoegen in Auto","uploaded_to_this_item":"Upload naar deze Auto","filter_items_list":"Filter Auto's lijst","items_list_navigation":"Auto's lijstnavigatie","items_list":"Auto's lijst","attributes":"Auto's attributen","name_admin_bar":"Auto","item_published":"Auto gepubliceerd","item_published_privately":"Auto priv\u00e9 gepubliceerd.","item_reverted_to_draft":"Auto omgezet naar concept.","item_scheduled":"Auto ingepland","item_updated":"Auto bijgewerkt.","parent_item_colon":"Hoofd Auto:"},"custom_supports":"","enter_title_here":"Voeg Auto toe"}}

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Hmm, not presently managing to recreate any noticeable issues around this, at least after having imported the settings for this post type.

    Thread Starter toondg

    (@toondg)

    Importing the blob I posted did fix the problem for me.
    If I then save the post type again on the edit page, the html encoded characters are back.
    For now I’ll just copy/paste the post types from the export to the import field after I make a change, to fix the issue.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Hopefully you’d only need to do that if you’re making any edits that include apostrophes, instead of every time regardless.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘‘ character in post type name is html encoded’ is closed to new replies.