WP Search Result Permalink need advice

  • Thread starter Thread starter richim1
  • Start date Start date
R

richim1

Guest
Hello guys...
I use %postname% on post permalink, so it looks like :
xxx.myblog.c0m/post-title

How can i change my search result permalink :
xxx.myblog.c0m/search/search+query
to
xxx.myblog.c0m/search+query
("/search/" deleted)
Without crash with post permalink...

Any suggest?
 
But i find a blog with permalink as described above...

There you have it, problem solved.
Contact the owner of that site and ask him.
Oh, and if the guy tells you, please3 tell me how it's done... i would also like to know. ;)
 
It using 404.php on your theme folder.
You need to edit the 404.php file so can show everything you want to show lol
I using this on my custom se with wordpress.
 
It using 404.php on your theme folder.
You need to edit the 404.php file so can show everything you want to show lol
I using this on my custom se with wordpress.

Wouldn't that be like... useless?
If you send a 404 to present the 404 page then search engines will also get a 404 and they won't index the page, so, no gain.
Unless i'm completely wrong and the 404 page doesn't send a 404 error and can be indexed.

I think you have to go a little deeper on the explanation.
 
It using 404.php on your theme folder.
You need to edit the 404.php file so can show everything you want to show lol
I using this on my custom se with wordpress.

Can u tell me how...?
 
OP:
I just online tru phone and I can't send a pm.
You can find permalink for search and remove it on wp-includes/rewrite.php
find "search" and delete it.

Try at your own risk.

See pdfboox.com
click on 1 link of recent searches then click 1 of result. As you can see, this is 404.php and indexed.
The bad things I can't post article on it.
 
OP:
I just online tru phone and I can't send a pm.
You can find permalink for search and remove it on wp-includes/rewrite.php
find "search" and delete it.

Try at your own risk.

See pdfboox.com
click on 1 link of recent searches then click 1 of result. As you can see, this is 404.php and indexed.
The bad things I can't post article on it.

Yes, i did...
I was delete "search" on rewrite.php , but as i mention above...when i create blog post, it will be search result. Blog post doesn't appear.
So how can i split between blog post and search result on the same permalink?
pdfboox.com is pure SEARCH, there is no has content.
 
Last edited:
i told you... you cant't do that.
Wordpress needs the /search/ slug so it can rewrite the URL to ?s=
If you take that out it will just look for a post with that permalink and if nothing found it will return a 404.
This won't work in a normal blog for sure.
In fact i even advise you to keep the post id in your pretty permalinks as it speeds up the retrieval of the posts from the database, like /%id%-%postname%/
maybe if you use these kind of permalinks you can do that hack, but i doubt it.
Consider yourself lucky for the search url using /search/ now instead of the ?s= it used some months ago...
Why don't you ask the same question in the wordpress support forums? They will have a definitive answer for you for sure ;)
 
I see giftawayoftheday can split it, between post and search result, but I don't know how their programer doing this.
I think it using if condition(I don't know the actual name for this php code) can split it.
If you have money, get a freelancer is the best way. You may also ask wordpress support to help or giving an example to split them though it hard to learn as said by SpiderWebMaster.
 
i told you... you cant't do that.
Wordpress needs the /search/ slug so it can rewrite the URL to ?s=
If you take that out it will just look for a post with that permalink and if nothing found it will return a 404.
This won't work in a normal blog for sure.
In fact i even advise you to keep the post id in your pretty permalinks as it speeds up the retrieval of the posts from the database, like /%id%-%postname%/
maybe if you use these kind of permalinks you can do that hack, but i doubt it.
Consider yourself lucky for the search url using /search/ now instead of the ?s= it used some months ago...
Why don't you ask the same question in the wordpress support forums? They will have a definitive answer for you for sure ;)

I see giftawayoftheday can split it, between post and search result, but I don't know how their programer doing this.
I think it using if condition(I don't know the actual name for this php code) can split it.
If you have money, get a freelancer is the best way. You may also ask wordpress support to help or giving an example to split them though it hard to learn as said by SpiderWebMaster.

Ok, thanks for the advice mate...
 
Back
Top