Hi

i am using var_dump, but after certain value it does not show full value and at the end it show like this

string....... (length=4480)

i want to get compete string. can anyone help me how can i do this. Let me know if i am not clear in my question

    This is a "feature" of xDebug. To fix it add the following to your php:

    xdebug.var_display_max_data=-1
    xdebug.var_display_max_children=-1
    xdebug.var_display_max_depth=-1
    

      Thanks for your message Derokorian

      can you please tell me from where i need to change this one? means in need to write php.ini?

        Just checking: you do have xDebug installed?

        Just double-checking: why can't you just use [man]echo[/man] to output the full string?

          waqasahmed996;11015911 wrote:

          Thanks for your message Derokorian

          can you please tell me from where i need to change this one? means in need to write php.ini?

          Yes sorry, I accidently backspaced over the .ini part because I forgot the code tags heh.

            Derokorian you are right. xDebux is not installed in local server but it is working on live server. Thanks a lot

              Derokorian actually i got one problem

              At local server i got information about xDebug using phpinfo() but face problem which i mentioned in my first post.

              But at live server i could not find any info about xDebug and it looks that xDebug is not installed at live server. That's why i get full string but without tags. Means var_dump show string as same way as echo normal string.

              What should i do know. First i think xDebug need to install on live server and then can you tell me which values need to check?

                waqasahmed996;11015927 wrote:

                At local server i got information about xDebug using phpinfo() but face problem which i mentioned in my first post.

                ... for which a solution was proposed in post #2 above.

                waqasahmed996;11015927 wrote:

                But at live server i could not find any info about xDebug and it looks that xDebug is not installed at live server. That's why i get full string but without tags. Means var_dump show string as same way as echo normal string.

                Great. So what's the problem?

                waqasahmed996;11015927 wrote:

                First i think xDebug need to install on live server

                Why would you want to do that?

                waqasahmed996;11015927 wrote:

                and then can you tell me which values need to check?

                Check for what? If you're talking about the same problem as you described in your original post, then you should use the same solution to that problem (as presented in post #2).

                  ok. what i got that first i need to install xDebug and then i need to change values mentioned in post#2 through php.ini. am i right?

                    the i could not understand one thing that at one server same data show result like this

                    string '<diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1"><Heiti xmlns="">

                    and on another server same data show result like this

                    tring(18344) "1123421018061Torfufell210000Reykjavík01Reykjavík1123421018063Torfufell230000Reykjavík01

                    what could be problem then i second server. i need info in tags

                      wagasahmed996 wrote:

                      Derokorian you are right. xDebux is not installed in local server but it is working on live server. Thanks a lot

                      Well, that's back to front: xDebug has no business being on the live server because the site is supposed to have already been debugged on the local server before being put on the live server.

                      what could be problem then i second server. i need info in tags

                      You're probably looking at everything in a browser, which would be trying to render it all as HTML (and therefore ignoring anything it doesn't recognise). Try looking at the source code the browser is receiving instead.

                        Thanks Weedpacket for you reply. You are right in source code it show in tags. Actually i need it in tags because i am getting this info from wsdl file via wsdl request. So if i need to get in tags to save in proper db fields. So i need to tell client that please request to hosting company to install xDebug🙂

                          waqasahmed996 wrote:

                          So i need to tell client that please request to hosting company to install xDebug

                          Wouldn't it be easier to look at the page source code like I suggested?

                          Weedpacket wrote:

                          Try looking at the source code the browser is receiving instead.

                          waqasahmed996 wrote:

                          So i need to tell client that please request to hosting company to install xDebug

                          Weedpacket wrote:

                          xDebug has no business being on the live server because the site is supposed to have already been debugged on the local server before being put on the live server

                            Thanks for your reply Weedpacket.
                            Actually my requirement is that i have wsdl file and i send SoapClient request to get some info. The output which i get through SoapClient is string but when i print that string using var_dump it is in different tags. I need to separate that output with respect to tags to get required information.

                            But problem i am facing is that in both servers (where xDebug installed and where it is not installed) i could not separate with respect to tags. In server where var_dump shows value in tags i am using function like this to get var_dump into string.

                            ob_start();
                            var_dump($someVar);
                            $result = ob_get_clean();
                            

                            but even then i am unable to use explode function (with any tag as a separator ) on variable $result to separate information. I stuck on this. i will be very thankful if you give me some more hint

                              If you're not debugging then you shouldn't be using debugging tools like xDebug or var_dump at all.

                              If you want to parse an XML document like that you would receive as a SOAP response, use an XML parser like that provided by [man]DOM[/man] or one of the other XML extensions. Assuming you wouldn't rather just use an existing SOAP library (like those in PEAR and Zend Framework).

                                Yes it works🙂 thanks a lot Weedpacket for your help and for your time🙂

                                  Write a Reply...