WordPress slug confusion

In wordpress down the side you goto Settings then to permalinks. From there you select a custom structure and can put it how ever you want. When you are creating a page after you have added in a title you can press the edit button to change the permalink.

Problems fixing a REST API 404 after Moving my WordPress Directory and updating Permalink Structure

This sounds like it might be an issue with how the files for the main Apache2 configuration file and those found in the virtual host are written. Adding the following line to the file * /etc/apache2/sites-available/hostname-le-ssl.conf before <Directory /var/www/html/hostname/public_html/> AllowOverride All Then restart apache2. $ sudo systemctl restart apache2 The files in /etc/apache2/sites-available are symlinked … Read more

Customize URL for specific tags archive

@ederico-dondi On your tag listing page, WordPress is getting the content of the page from your url querystring. In your case, there is “tag” in your url so it will understand that you are on tag page. If you will remove tag then it will not show data of tag. for example. the below code … Read more

WordPress Attachment Page URL Rewrite!

There are three issues in your code: In your custom wp_attachment_link() function, you should use the post slug ($attachment->post_name) instead of simply replacing the (whitespaces) with – (dash) in the post title — and note that the resulting slug could be different than the actual slug, e.g. the title could be My Image with the … Read more

Convert $ _GET to permalink

Probably the easiest way to solve this would be to add classes to your body tag based on the value of the parameter. You would just want to be sure to sanitize it. You can add classes to the body using the body_class filter which feeds in all the current classes as an array. You … Read more