Php fputcsv在不应该引用的地方加上引号';T

Php fputcsv在不应该引用的地方加上引号';T,php,fputcsv,Php,Fputcsv,我正在写一个脚本,将产品导出到GoogleBase。。。问题是,当我在股票中使用以下代码时,in stock被输出为“in stock”,而谷歌没有意识到这一点,它只意识到它没有报价。我不知道有什么方法可以不加引号的做到这一点 $row = array( 'new', $product->getSku().'-'.$vehicle-

我正在写一个脚本,将产品导出到GoogleBase。。。问题是,当我在股票中使用以下代码时,
in stock
被输出为
“in stock”
,而谷歌没有意识到这一点,它只意识到它没有报价。我不知道有什么方法可以不加引号的做到这一点

                        $row = array(
                            'new',
                            $product->getSku().'-'.$vehicle->getId(),
                            'https://www.domain.com/vehicles/'.str_replace(' ', '-', $make->getName()).'/'.str_replace(' ', '-', $model->getName()).'/'.$year.'/'.$product->getId(),
                            $this->tru->config->get('root.cdn.url').'-products/'.$product->getPicture(),
                            $product->getSellPrice(),
                            $title,
                            $year,
                            'in stock',
                            $product->getFCCID(),
                            'Visa,Mastercard,Discover,AmericanExpress',
                            'US::Ground:4.95,CA::Ground:28.95',
                            'small',
                            'Vehicles & Parts > Automotive Locking Systems > Remote Keyless Systems'
                        );

                        fputcsv($output, $row, $seperatorValue);

我认为编写自己的函数比使用fputcsv()更好

以下代码行中的某些内容

$output = fopen("path/to/your/file.csv", "a+");

$line = join(',', $row);

fwrite($output, $line);

fclose($output);

希望这有帮助

单独的$value值多少?如果在$row数组中使用双引号而不是单引号,会发生什么情况?$separatorvalue=chr(9);-它能逃过双引号吗?chr(9)这不是一个空间吗?回声“Char:|”。.chr(9)。“|\n”;