I would like to add GET Parameters to my wordpress pages url like so the page url would be like:
mywebsite.com/parent/mypage?social=facebook
But I cannot manage to do so :(
Any help would be much appreciate.
Thanks
A GET parameter isn't included in quotes in the URL - omit them
Related
Upon publishing a post through the nice WordPress plugin "Press-this extended" redirects to the published post appending a string on the url which all other posts do not have. The url is as follows: mysite.com/?post_type=post&p=xxxx as opposed to the regular ones which have just: mysite.com/?p=xxxx
What is wanted is simply the omission of the "post_type=post&" string from the urls that have it, which are only the urls generated by this plugin. Using the classic editor does not add this string.
What's the simplest way of achieving this? By a function? By htaccess?
I searched and tried similar questions and solutions but could not resolve it.
Any advice would be appreciated.
I want to create user friendly wordpress pages url's.
I want to make url like this for example:-
http://www.example.com/234
here 234 is any integer number assigned by admin for the pages.
when i am trying to do this then it automatically adding -2 with the url's and also page with this url is not working.
Any help for this would be appreciated.
Thanks in advance.
Assuming that you have your .htaccess file correct, you'll have a -2 appended to the url in case you are setting a value which already exists for another post. Check your posts again to see if there's any post with that permalink (including posts saved as draft).
I need little help for url rewriting in wordpress.
basically what i need:
mydomain.com/mysomewordpresspost
mydomain.com/parentpage/subpage
to
mydomain.com/global/mysomewordpresspost.
mydomain.com/global/subpage
Basically want to add "global" in url
and also for subpages, categories, post etc etc.
mean all long url short to "global"
No want to show categorname in url and parent page name in url.
You can do this easily, Just add like this in your Permalink Settings->Custom Structure
/global/%postname%/
I am not a wordpress guy and a client needs me to modify some pages. Someone else has created the entire site in wordpress.
I am having trouble with a query string that contains variables.
wordpresssite.com/pages-using-template/?variable=something
This causes the page to get thrown to the default 404 for the site..
Any suggestions on which file i need to fix this in and how to do it?
Thanks
wordpresssite.com/pages-using-template/?variable=something
That's giving you a 404 error, probably because you're trying to add the query string variable to the home page of the site. There's no "file" that fixes this - WordPress is dynamic. the .htaccess rules handle the URL rewrites ("pretty permalinks")
So I guess you need to give more information on what it is you're trying to do. There's not going to really be a way to "fix" the URL without breaking the rest of the site (it's possible, but I'm betting that whatever it is you're trying to do requires a much simpler solution).
What query string are you trying to add in? For what reason?
For example, I recently did a WordPress site from someone who needed a directory on one page of the site, that had a custom search from in it. I created a function that would $_GET the URL of the page and add the search query to it, and then return the end user to the page with the results there.
You also have to be careful about the $_GET in your functions - you want to be sure they're protected against injection attacks by using $wpdb->escape($_GET['xxx']).
I was wondering if it's possible to rewrite the url of a post to keep the current url as permalink and add the post name at the end of current url. I ask this because I've created a custom WP_Query and integrated that in a page.
So I want the url to be like http://sitename.me/pagename (here is the custom query) and the post link would look like http://sitename.me/pagename/postname instead of sitename.me/category/postname.
Do you have any suggestions how can this be achieved?
Thanks,
Ciprian
You are asking to fetch someone with out knowing their identity!
You will have to send the postname some way or the other. May be through Input Type=Hidden and fetch it from the query-string.