Ben diğer benzer sorulara cevap için baktım ama yararlı göremiyordu ..
I have an html table generated with php from mysql db. I use this fragment in my php file to save as excel
$file="program.xls"; header('Content-Type: text/html'); $table = $_POST['tablehidden'];//i get this from another php file.It is HTML table header("Content-type: application/x-msexcel"); //tried adding charset='utf-8' into header header("Content-Disposition: attachment; filename=$file"); echo $table;
- Bu zamana kadar her şey tamam. Ben bu kaydederken ama karakter sorunu olsun ve charset='utf-8' benim başlığı içine eklemek için bilmiyorum ama bu çalışmıyor çalıştı.
- Ben HTML tarzı ile benim tablo var ama excel geldiğinde css uygulanan stilini kaybetti.
Ben nasıl charset ve stil sorunları çözebilir? Ben phpexcel baktım ancak doğrudan bir tablo eklemek için bir yöntem göremiyordu.