问题描述
大家好!
我会研究一种网络编程语言来创建一个PHP脚本
(output.php),给出以下
输入页面(input.htm),用户选择要装运的
包裹的重量和体积,返回各种快递的价格(黄色,
蓝色和黑色)。
真的是PHP我最好的选择吗? ASP要复杂得多吗?那怎么样?
Perl?
~~~输入页面输入.htm:
< form method = QUOT; GET"行动= QUOT; output.php" name =" input">
选择您的套餐音量:
< input type =" radio"名称= QUOT;体积"值= QUOT 1 QUOT;>从0到1立方米
< input type =" radio"名称= QUOT;体积"值= QUOT; 2英寸;>从1到2立方米
< input type =" radio"名称= QUOT;体积"值= QUOT; 3英寸;>从2到3立方米
< br>选择您的包装重量:
< input type =" radio"名称= QUOT;重量"值= QUOT; 100">从0到100 Kg
< input type =" radio"名称= QUOT;重量"值= QUOT; 200">从100到200公斤
< input type =" radio"名称= QUOT;重量"值= QUOT; 300">从200到300公斤
~~~要在output.php中集成的结构脚本:
Courier黄色 - 对于第1,2和3卷:
如果重量= 100然后费率= 600
如果重量= 200然后费率= 900
如果重量= 300然后费率= 1200
Courierblue - 第1卷和第2卷:
如果重量= 100则速率= 400
如果重量= 200则速率= 700
Courierblack - 对于第2卷和第3卷:
如果权重= 100则速率= 800
如果权重= 200则速率= 1100
如果权重= 300然后费率= 1500
~~~样品申请和结果:
例A)用户输入:
卷= 2
重量= 300
output.php必须产生这样的结果:
courier"黄色" = 1200
courier" black" = 1500
例B)用户输入:
音量= 1
重量= 100
output.php必须生成此结果:
courier" yellow" = 600
courier" blue" = 400
作为以前的ASP编码器切换到PHP我会反驳这一点。
有一个非常强大的usenet社区支持ASP和许多MVP
加盖ASP相关的网站和教程。工作情况非常真实
然而 - 不幸的是。我原本被聘为ASP程序员
并按下我的公司进行切换,但我经常感觉好像
我是少数几个在那里工作的人之一。
J
Hi all!
I would to study a web programming language to create a PHP script
(output.php) that, given the following
input page (input.htm) where the user select the weight and volume of a
package to be shipped, returns the prices of various couriers ("yellow",
"blue" and "black").
Really is PHP my best choice? ASP is much more complicated? and what about
Perl?
~~~ input page input.htm:
<form method="GET" action="output.php" name="input">
SELECT THE VOLUME OF YOUR PACKAGE:
<input type="radio" name="volume" value="1"> from 0 to 1 m3
<input type="radio" name="volume" value="2"> from 1 to 2 m3
<input type="radio" name="volume" value="3"> from 2 to 3 m3
<br>SELECT THE WEIGHT OF YOUR PACKAGE:
<input type="radio" name="weight" value="100"> from 0 to 100 Kg
<input type="radio" name="weight" value="200"> from 100 to 200 Kg
<input type="radio" name="weight" value="300"> from 200 to 300 Kg
</form>
~~~ istructions to be integrated in the "output.php" script:
Courier "yellow" - for volume 1, 2 and 3:
if weight=100 then rate=600
if weight=200 then rate=900
if weight=300 then rate=1200
Courier "blue" - for volume 1 and 2:
if weight=100 then rate=400
if weight=200 then rate=700
Courier "black" - for volume 2 and 3:
if weight=100 then rate=800
if weight=200 then rate=1100
if weight=300 then rate=1500
~~~ sample request and result:
Example A) With the user input:
volume=2
weight=300
output.php must generate this result:
courier "yellow" = 1200
courier "black" = 1500
Example B) With the user input:
volume=1
weight=100
output.php must generate this result:
courier "yellow" = 600
courier "blue" = 400
I assume you mean a broader free community. There is a huge industry
behind ASP, and millions of people programming with it, but its all
high dollar. I''m impressed with the fact that when I open the
newspaper and look at the want ads there are several requests for ASP
and none for PHP. Yet if you go looking for advice, it is easy to find
tons of free advice and free code for PHP. With ASP, no one gives
advice without charging for it.
I assume you mean a broader free community. There is a huge industry
behind ASP, and millions of people programming with it, but its all
high dollar. I''m impressed with the fact that when I open the
newspaper and look at the want ads there are several requests for ASP
and none for PHP. Yet if you go looking for advice, it is easy to find
tons of free advice and free code for PHP. With ASP, no one gives
advice without charging for it.
As a former ASP coder that made the switch to PHP I''d refute this.
There is a very strong usenet community standing behind ASP and many MVP
stamped ASP related sites and tutorials. The job situation is very real
however -- unfortunatly. I was originally hired as an ASP programmer
and press-ganged my company into making the switch but I often feel like
I am one of the few actually salaried out there.
J
这篇关于PHP是更简单的Web编程语言吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!