标签:put opened utf-8 closed pre name img encode post
function create_auto_html($params, $action) { $encodeType = isset ($params [‘encoding‘]) ? $params [‘encoding‘] : ‘UTF-8‘; $html = <<<eot <html> <head> <meta http-equiv="Content-Type" content="text/html; charset={$encodeType}" /> </head> <body onload="javascript:document.pay_form.submit();"> <form id="pay_form" name="pay_form" action="{$action}" method="post"> eot; foreach ($params as $key => $value) { $html .= " <input type=\"hidden\" name=\"{$key}\" id=\"{$key}\" value=\"{$value}\" />\n"; } $html .= <<<eot </form> </body> </html> eot; return $html; }
标签:put opened utf-8 closed pre name img encode post
原文地址:https://www.cnblogs.com/cuizhenyu/p/10604223.html