How to get the strings in the link to PHP-php Tutorial

Source: Internet
Author: User
How can I get the strings in the link to PHP? how can I get the strings in the link to PHP? For example, the link is www.xxxxx.com. cngoods. php? Goods_id183 program: & lt; INPUTnamegoods_idvalue183typehidden & gt; & lt; INPUTnamebaseurlvaluew
How can I get the strings in the link to PHP?
For example, the link is http://www.xxxxx.com.cn/goods.php? Goods_id = 1, 183

Program entry:



The problem is as follows:
Statement value = 183. When 183 in the link is changed to another number, the VALUE followed by the value also changes. I know that requests are implemented in ASP, but PHP won't. please help me.

------ Solution --------------------
If (! Empty ($ _ GET ['goods _ id']) {
$ Value = intval ($ _ GET ['goods _ id']);
} Else {
$ Value = '';
}
?>
Type = hidden>
------ Solution --------------------
PHP code
  
  
------ Solution --------------------
Discussion

ASP statement is
<% Good_id = request ("good_id") %>

Type = hidden>


Please help. thank you.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.