IT入门 > 教程 > php教程 >
  • 绘制线段与圆弧

    2019/12/10 点击:409

    imageline() 函数用于绘制一条线段。 imagearc() 函数用于绘制椭圆弧(包括圆弧)。 imagesetstyle() 函数用于设定画线风格。 imageline() imageline() 函数用于绘制一条线段。 语法: bool imageline(

  • imagesetstyle()

    2019/12/10 点击:249

    imagesetstyle() 设定所有画线的函数(例如 imageline() 和 imagepolygon())在使用特殊颜色 IMG_COLOR_STYLED 或者用 IMG_COLOR_STYLEDBRUSHED 画一行图像时所使用的风格。如果成功则返回 TRUE ,失败则返回

  • imagearc()

    2019/12/10 点击:277

    imagearc() 函数用于绘制椭圆弧(包括圆弧)。 语法: bool imagearc(resource image, int cx, int cy, int w, int h, int s, int e, int color ) 参数说明: 参数 说明 image 图像资源,欲绘制椭圆弧的图像 cx 椭圆

  • 图像填充

    2019/12/10 点击:237

    imagefill() 函数用于图像区域填充。 imagefilledarc() 函数画一椭圆弧并填充。 imagefilledrectangle() 函数画一矩形并填充。 imagefilledpolygon() 函数画一多边形并填充。 imagefill() imagefill() 函数用于

  • imagefilledarc()

    2019/12/10 点击:302

    imagefilledarc() 函数画一椭圆弧并填充。 语法: bool imagefilledarc( resource image, int cx, int cy, int w, int h, int s, int e, int color, int style ) 该函数参数用法可参考绘制椭圆弧函数 imagearc() ,只是本函

  • imagefilledrectangle

    2019/12/10 点击:224

    imagefilledrectangle() 函数画一矩形并填充。 语法: bool imagefilledrectangle( resource image, int x1, int y1, int x2, int y2, int color ) x1,y1为左上角左边,x2,y2为右下角坐标。 例子: ?phpheader('Content-type:

  • imagefilledpolygon()

    2019/12/10 点击:299

    p imagefilledpolygon() 函数画一多边形并填充。 /p p 语法: /p prebool imagefilledpolygon( resource image, array points, int num_points, int color ) /pre table class=table caption参数说明:/caption tbodytr th width=15%参数

  • PHP 普通数学计算

    2019/12/10 点击:258

    PHP 普通数学计算直接使用算术运符: +:加法 -:减法 *:乘法 /:除法 %:取模,得到 A 除以 B 的余数 ++:递增,该值加 1 --:递减,该值减 1

  • 加减乘除计算

    2019/12/10 点击:373

    ?php$x = 10;$y = 2;$result = $x + $y;//结果:12$result = $x - $y;//结果:8$result = $x * $y;//结果:20$result = $x / $y;//结果:5? 其中减法运算符(-)还可以单独使用,称为取反,即取得某个数的负值:

  • PHP 取模

    2019/12/10 点击:898

    取模即得到两个数相除的余数: ?php$x = 10;$y = 3;$resule = $x % $y;//结果:1? 提示 ($x % $y)在 $x 为负值时取模的结果也是负值。 取模运算常用于各种循环判断中,如取出偶数记录等。