')); if ($h == 0) { $h=$height; } if ($w == 0) { $w=$width; } if (isset($_GET['insvg'])) { $lastcontent='')); $w+=40; //$w=(($w + 20) / 20) * 20; $h+=40; //$h=(($h + 20) / 20) * 20; if ($vbox != '') { $vbox=' viewBox="0 0 ' . $w . ' ' . $h . '" '; $pw=$w; $ph=$h; } } } else if (isset($_POST['image'])) { list($width, $height) = getimagesize(str_replace('+',' ',urldecode($_POST['image']))); $lastcontent='')); if ($h == 0) { $h=$height; } if ($w == 0) { $w=$width; } if (isset($_POST['insvg'])) { $w+=40; //$w=(($w + 20) / 20) * 20; $h+=40; //$h=(($h + 20) / 20) * 20; if ($vbox != '') { $vbox=' viewBox="0 0 ' . $w . ' ' . $h . '" '; $pw=$w; $ph=$h; } } } if ($pw == '' && $h != 0) { $pw=$w; } if ($ph == '' && $h != 0) { $ph=$h; } if (isset($_GET['text'])) { $txt=str_replace("\n","
",str_replace(' ',' ',str_replace('+', ' ', urldecode($_GET['text'])))); $minus30=($w / 2.0) - strlen(explode('
', $txt)[0]) * 3.1; $top30=($h / 2.0) + 25 - (sizeof(explode('
', $txt)) * 8); $lines=explode('
', $txt); for ($il=0; $il' . $lines[$il] . ''; $top30+=15; } } else if (isset($_POST['text'])) { $txt=str_replace("\n","
",str_replace(' ',' ',str_replace('+', ' ', urldecode($_POST['text'])))); $minus30=($w / 2.0) - strlen(explode('
', $txt)[0]) * 3.1; $top30=($h / 2.0) + 25 - (sizeof(explode('
', $txt)) * 8); $lines=explode('
', $txt); for ($il=0; $il' . $lines[$il] . ''; $top30+=15; } } if (isset($_GET['insvg'])) { $innards=str_replace('+',' ',urldecode($_GET['insvg'])); $preinnards='&#' . str_replace(',',';&#',$innards) . ';'; $svgprefix=''; $svgsuffix=''; if (strpos($innards, ''; } else { $svgprefix=''; } $svgsuffix=''; if (trim(str_replace(',','',str_replace('0','',str_replace('1','',str_replace('2','',str_replace('3','',str_replace('4','',str_replace('5','',str_replace('6','',str_replace('7','',str_replace('8','',str_replace('9','',$innards)))))))))))) == '') { for ($x=0; $x<=$w; $x+=20) { for ($y=0; $y<=(0 + $h); $y+=20) { if ($x == 0 && $y == 0) { $innards='' . $preinnards . ''; if ($h > 0) { $innards.='' . $preinnards . ''; } } else if (isset($_GET['background']) || isset($_GET['image']) || $x == 0 || $y == 0 || ($x + 20) > $w || ($y + 20) > (0 + $h)) { $innards.='' . $preinnards . ''; $innards.='' . $preinnards . ''; } } } } } echo ' ' . $svgprefix . $innards . $lastcontent . $textcontent . $svgsuffix; } else if (isset($_POST['insvg'])) { $innards=str_replace('+',' ',urldecode($_POST['insvg'])); $preinnards='&#' . str_replace(',',';&#',$innards) . ';'; $svgprefix=''; $svgsuffix=''; if (strpos($innards, ''; } else { $svgprefix=''; } $svgsuffix=''; if (trim(str_replace(',','',str_replace('0','',str_replace('1','',str_replace('2','',str_replace('3','',str_replace('4','',str_replace('5','',str_replace('6','',str_replace('7','',str_replace('8','',str_replace('9','',$innards)))))))))))) == '') { for ($x=0; $x<=$w; $x+=20) { for ($y=0; $y<=(0 + $h); $y+=20) { if ($x == 0 && $y == 0) { $innards='' . $preinnards . ''; if ($h > 0) { $innards.='' . $preinnards . ''; } } else if (isset($_GET['background']) || isset($_GET['image']) || $x == 0 || $y == 0 || ($x + 20) > $w || ($y + 20) > (0 + $h)) { $innards.='' . $preinnards . ''; $innards.='' . $preinnards . ''; } } } } } echo ' ' . $svgprefix . $innards . $lastcontent . $textcontent . $svgsuffix; } else if (isset($_POST['image']) || isset($_GET['image'])) { echo ' ' . $lastcontent . ' '; } else { echo ' '; } ?>