0, "!"=>1, "\""=>2, "#"=>3, "$"=>4, "%"=>5, "&"=>6, "'"=>7, "("=>8, ")"=>9, "*"=>10, "+"=>11, ","=>12, "-"=>13, "."=>14, "/"=>15, "0"=>16, "1"=>17, "2"=>18, "3"=>19, "4"=>20, "5"=>21, "6"=>22, "7"=>23, "8"=>24, "9"=>25, ":"=>26, ";"=>27, "<"=>28, "="=>29, ">"=>30, "?"=>31, "@"=>32, "A"=>33, "B"=>34, "C"=>35, "D"=>36, "E"=>37, "F"=>38, "G"=>39, "H"=>40, "I"=>41, "J"=>42, "K"=>43, "L"=>44, "M"=>45, "N"=>46, "O"=>47, "P"=>48, "Q"=>49, "R"=>50, "S"=>51, "T"=>52, "U"=>53, "V"=>54, "W"=>55, "X"=>56, "Y"=>57, "Z"=>58, "["=>59, "\\"=>60, "]"=>61, "^"=>62, "_"=>63, "`"=>64, "a"=>65, "b"=>66, "c"=>67, "d"=>68, "e"=>69, ""=>70, "g"=>71, ""=>72, "i"=>73, "j"=>74, "k"=>75, "l"=>76, "m"=>77, "n"=>78, "o"=>79, "p"=>80, "q"=>81, "r"=>82, "s"=>83, "t"=>84, "u"=>85, "v"=>86, "w"=>87, "x"=>88, "y"=>89, "z"=>90, "{"=>91, " "=>92, "}"=>93, "~"=>94, "DEL"=>95, "3"=>96, "2"=>97, "SHIFT"=>98, "CODE C"=>99, "CODE B"=>100, "FNC 4"=>101, "FNC 1"=>102, "StartA"=>103, "StartB"=>104, "StartC"=>105, "Stop"=>106 ); $bs = array( 0=>"212222", "222122", "222221", "121223", "121322", "131222", "122213", "122312", "132212", "221213", "221312", "231212", "112232", "122132", "122231", "113222", "123122", "123221", "223211", "221132", "221231", "213212", "223112", "312131", "311222", "321122", "321221", "312212", "322112", "322211", "212123", "212321", "232121", "111323", "131123", "131321", "112313", "132113", "132311", "211313", "231113", "231311", "112133", "112331", "132131", "113123", "113321", "133121", "313121", "211331", "231131", "213113", "213311", "213131", "311123", "311321", "331121", "312113", "312311", "332111", "314111", "221411", "431111", "111224", "111422", "121124", "121421", "141122", "141221", "112214", "112412", "122114", "122411", "142112", "142211", "241211", "221114", "413111", "241112", "134111", "111242", "121142", "121241", "114212", "124112", "124211", "411212", "421112", "421211", "212141", "214121", "412121", "111143", "111341", "131141", "114113", "114311", "411111", "411311", "113141", "114131", "311141", "411131", "211412", "211214", "211232", "2331112" ); header("Content-type: image/gif"); $word = rawUrlDecode($word); if(!empty($width)){ $wid = $width; $x = $width/2 - ((strLen($word)*22)+37)/2; } else{ //$x = 472 - ((strLen($word)*22) + 37); $x = 0; $wid = (strLen($word)*22) + 68 + $x; } //$ht = 2; $ht = 100; $im = imageCreate($wid,$ht); $white = imageColorAllocate($im,255,255,255); $black = imageColorAllocate($im,0,0,0); // START CHAR $stripes = $bs[$codes["StartB"]]; stripeChar($stripes,$im,$black,$x,$ht); $tot = 104; for($i=0; $i=0 && $indx <103){ $tot += (($i+1) * $codes[$c]); $stripes = $bs[$codes[$c]]; stripeChar($stripes,$im,$black,$x,$ht); } } // SANITY CHECK CHAR $stripes = $bs[($tot%103)]; stripeChar($stripes,$im,$black,$x,$ht); // STOP SEQUENCE imageFilledRectangle($im,$x,$ht-1,$x+3,$ht,$black); imageFilledRectangle($im,$x+10,$ht-1,$x+15,$ht,$black); imageFilledRectangle($im,$x+18,$ht-1,$x+19,$ht,$black); imageFilledRectangle($im,$x+22,$ht-1,$x+25,$ht,$black); #imageFilledRectangle($im,$x,0,$x+1,$ht,$black); #imageFilledRectangle($im,$x+5,0,$x+7,$ht,$black); #imageFilledRectangle($im,$x+9,0,$x+9,$ht,$black); #imageFilledRectangle($im,$x+11,0,$x+13,$ht,$black); $x = $width/2 - ((strLen($word)*11)+37)/2; for($i=$wid/2;$i>$wid/2-100;$i--){ imageCopyResized($im,$im,$wid/2-$i,$i-$wid/2+100,0,99,2*$i,1,$wid,1); } imageGif($im); imageDestroy($im); ?>