php - Use Search Term in html link and redirect

i want to make a redirect with the search from users termquery from the user. the term should be after the s= and befor

i want to make a redirect with the search from users term/query from the user. the term should be after the s= and before the &post_type=post

thanks for help

this is my code but i get critical error on wordpress:

<p class="woocommerce-info"><?php wp_redirect( "/?s="<?php echo get_search_query(); ?>"&post_type=post" ); ?></p>

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1742352037a4427711.html

相关推荐

  • php - Use Search Term in html link and redirect

    i want to make a redirect with the search from users termquery from the user. the term should be after the s= and befor

    2小时前
    10

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信