简体   繁体   中英

How can I combine multiple functions in my address using PHP?

I have created two different functions that work from the address bar. Now I need to combine them. The first I'm passing on a variable.

http://address.com/mimowg.php?g1

I need to add this after this. In Python it's a + ; what is it in PHP ?

?scd=/net/mfg-scd8/et3mach/status.txt

What is the best way to combine these two statements to one working address?

使用&符号( & )向您的URL添加多个GET参数。

http://address.com/mimowg.php?g1&scd=/net/mfg-scd8/et3mach/status.txt

要在GET请求中使用多个参数,请使用&组合它们。

http://address.com/mimowg.php?g1&?scd=/net/mfg-scd8/et3mach/status.txt

Your terminology is a little convoluted. But it sounds like you are asking to provide multiple GET parameters to the URL. This is the same whether it's php or python or for anything using http.

You separate multiple parameters using an & . The first parameter follows a ?

So your url would be something like

http://address.com/mimowg.php?g1&scd=/net/mfg-scd8/et3mach/status.txt

Although it's better to either name both parameters or leave them both unnamed like:

http://address.com/mimowg.php?p1=g1&scd=/net/mfg-scd8/et3mach/status.txt

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM