Set permalink to (Post Name)
or
http://www.example.com/[blog_name]`/%post_id%/%postname%/`
Add following code to functions.php
of your theme:
add_filter ( 'alias_rule', 'xili_language_trans_slug_qv' ) ;
function xl_permalinks_init () {
global $XL_Permalinks_rules;
if (class_exists('XL_Permalinks_rules') ) {
$XL_Permalinks_rules = new XL_Permalinks_rules ();
add_permastruct ( 'language', '%lang%', true, 1 );
add_permastruct ( 'language', '%lang%', array('with_front' => false) );
}
}
Related Posts:
- Change the “page” slug in pagination
- Change author base slug for different roles
- Using custom/dynamic “slug” for a page
- Display posts with author in the url with custom post types
- How to seamlessly redirect between different archive and singular slugs?
- How to add dot(“.”) in post slug
- How to change default page slug?
- Handle category name URL rewrite before different post type slugs
- custom htaccess rewrite rule for page
- Why is there /index.php/ in all my links? How do I remove it?
- Multilingual theme: Changing locale based on URL
- How make a multi language routes, with rewrite rules or rewrite endpoints?
- Multiple Permalinks for Same Post
- Adding more pages to author pages
- Using Blog Parent Slug on Blog Posts Only
- Load a template page based on part of slug in wordpress
- Removing “category” from URLs then “add_endpoint()” won’t work…
- Use custom template on certain URLs
- How do I change attachment slug from name to id
- Access files at new location using old file paths
- Adding special characters to slug?
- Rewrite URLs – Custom Post Type – Post Slug, Taxonamy Slug
- Translate custom post type and taxonomy slug in URL?
- Preserve old website URL structure after migrating to WordPress
- WPML language switcher for custom rewrite rules
- How to change the Author Slug from Username to Nickname and deal with Special Characters
- How to change custom post type slug
- Disable WordPress from changing URL slug when post is published
- Using URL rewrite to add custom URL for custom post type
- One off rewrite for single post-type slug (show normal page with same URL instead)
- Can’t use a specific custom URL (slug)?
- How to transform multiple parameter URL to clean URL
- Make the home page’s slug visible in the browser’s URL bar
- Trying to add array of paths to post permalink
- Changing the wordpress default search url to something like – …example.com/search?query=keyword
- How to add dot(“.”) in post slug
- WordPress is adding “category” word before my actual category name in url (and this is unsolicited)
- Change author base and slug in author link
- WordPress numeric (yearly) page names / disable yearly archives
- Post & Page with same slug
- How to add 2 variable rewrite rule?
- taxonomy term in URL slug won’t forward to the correct term for custom post like it does for default categories/normal posts
- Remove Page Slug from URL
- Needed to change slug to access page
- What’s the best approach to do this?
- Pagination posts. Url format
- Change the slug ( url ) to a sequence number starting from 0 in the custom record type?
- WordPress pagination error when using ACF CPT rewrite slug & Polylang CPT slug translation
- Switch WordPress to non-absolute links? [closed]
- How to create custom URL routes?
- How do you create a “virtual” page in WordPress
- How to create a front end user profile with a friendly permalink
- Use a template file for a specific url without creating a page
- Using the Rewrite API to Construct a RESTful URL
- Does WordPress keep track of a post’s URL history and provide automatic redirects?
- Change the Author Slug from Username to Nickname
- Understanding add_rewrite_rule
- Override default url for author pages?
- web.config conflict on IIS
- Rewrite Slug for CPT Archive Pages to Plural Name of Slug
- Masking wp-content/themes/name/images to just images directory using htaccess
- custom taxonomy and pages rewrite slug conflict gives 404
- Two (or more) parallel (sub-)TLDs that are retained when surfing the site / dynamically set the site address?
- Remove taxonomy base or term from url
- Creating custom permalink structure for languages
- How to make pages slug have priority over any other taxonomies like custom-post, post or category
- Rewrite rules not working in WordPress
- How to retrieve $_GET variables from rewritten URLs?
- Dynamic Endpoints
- Passing parameters to a custom page template using clean urls
- rewrite rules and querystring
- Adding rewrite endpoint breaks static front page
- How to add custom rewrite rule to .htaccess?
- How do I remove a rewrite rule?
- How do I add a server-independent external rewrite rule?
- Multiple endpoints to same page
- Problem with add_rewrite_rule and pagination (paged and page query_vars)
- Use subdomain for certain urls
- Custom Permalinks for Blog Posts Only
- Unique URL Every Time
- generate_rewrite_rules (action) vs add_rewrite_rule (function): which one is preferred?
- Detect page type by url (Archive, single, page, author,…)
- Rewrite URL – how to do a SEO-friendly Unicode custom URL?
- I want to create a custom slug in WordPress and output JSON. How do I do this?
- How to make a category page the blog home page?
- add_rewrite_rule: $matches var not replaced by captured value
- Can I call a custom plugin with a direct URL
- How to show the same content on multiple URLs?
- Custom slug in front of search URL
- Custom rewrite rules for pages
- Rewrite default post type
- Custom permalinks with NextGEN Gallery
- Clash of the rewrites
- Using a page template without a page
- External/non-WP rewrite rules
- How-to add rewrite rules to point the uploads folder to a subdomain
- Rewrite Rules for Multiple (more than 2) Taxonomies
- Create built-in pages without creating actual pages
- Is the SEO plugin necessary?
- Can ‘numberposts’ be passed in the URL query string?