小程序详情适配

feat/task1-c-wallet
devil_gong 2019-08-07 10:48:36 +08:00
parent 6b81ce5be4
commit 3900411bbb
1 changed files with 2 additions and 0 deletions

View File

@ -85,6 +85,7 @@ class Goods extends Common
'<div>',
'<table ',
'<td ',
'<th ',
];
$replace = [
'<img style="max-width:100%;margin:0;padding:0;display:block;" ',
@ -94,6 +95,7 @@ class Goods extends Common
'<div style="margin:0;">',
'<table style="width:100%;margin:0px;border-collapse:collapse;border-color:#ddd;border-style:solid;border-width:0 1px 1px 0;" cellspacing="0" cellpadding="0" ',
'<td style="margin:0;padding:5px;border-color:#ddd;border-style:solid;border-width:1px 0 0 1px;" ',
'<th style="margin:0;padding:5px;border-color:#ddd;border-style:solid;border-width:1px 0 0 1px;" ',
];
$ret['data'][0]['content_web'] = str_replace($search, $replace, $ret['data'][0]['content_web']);
}