Giter Site home page Giter Site logo

Character problem about simplexls HOT 5 CLOSED

shuchkin avatar shuchkin commented on August 27, 2024 1
Character problem

from simplexls.

Comments (5)

shuchkin avatar shuchkin commented on August 27, 2024

try set page charset before output
header('Content-Type: text/html; charset=utf-8');
$xls = SimpleXLSX::parse....

from simplexls.

memo20yorga avatar memo20yorga commented on August 27, 2024

I have the same issue. Some of the some türkish charachters "Ü,ü,Ö,ö" sometimes are read wrong. In the same cell when I change cell context it is read one time wrong one time right. interesting issue.

from simplexls.

shuchkin avatar shuchkin commented on August 27, 2024

class works good with unicode, just don't forget set output charset:

header('Content-Type: text/html; charset=utf-8');

one time wrong one time right --- so browser charset autodetection not perfect without this header

from simplexls.

memo20yorga avatar memo20yorga commented on August 27, 2024

Thanks for your reply. I expressed myself wrong. sorry about my english. I'm trying to import excel file which includes turkhish characters. I read excel file and record them to the database with code shown below.
If you think it is appropriate I can send you my excel file which I made my trials

        header('Content-Type: text/html; charset=utf-8');
        $xls = new SimpleXLS($excelFilePath);
        $headers = $rows = [];
        //echo "<pre>";
        if ($xls->success()) {

            print_r($xls->rows());
            foreach ($xls->rows() as $k => $r) {
                if ($k === 0) {
                    $headers = $r;
                    continue;
                }else{
                    if($r[0]!=""){
                        $katilimci_bulk = new FuarKatilimci();
                        $katilimci_bulk->setFirmaAdi($r[0]);
                        $katilimci_bulk->setHolNo($r[1]);
                        $katilimci_bulk->setStantNo($r[2]);
                        $katilimci_bulk->setYetkili($r[3]);
                        $katilimci_bulk->setMail($r[4]);
                        $katilimci_bulk->setTelefon($r[5]);
                        $katilimci_bulk->setFax($r[6]);
                        $katilimci_bulk->setAdres($r[7]);
                        $katilimci_bulk->setSehir($r[8]);
                        $katilimci_bulk->setUrunGrubu($r[9]);
                        $katilimci_bulk->setFuar($entity->getFuar());


                        $em->persist($katilimci_bulk);
                        $em->flush();
                    }
                }
            }

from simplexls.

shuchkin avatar shuchkin commented on August 27, 2024

If you think it is appropriate I can send you my excel file which I made my trials

no, thx, have nice day )

from simplexls.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.