Help with regular expressions

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Glenton
    Recognized Expert Contributor
    • Nov 2008
    • 391

    #16
    As I said, it might be that it only gives the data the first time. Try to set some variable equal to parser.data, and then use that variable from there on.

    You need to find out why parser.data is empty when it comes to the moment to use it!

    Comment

    • Glenton
      Recognized Expert Contributor
      • Nov 2008
      • 391

      #17
      But to answer your question, no, I can't think of a reason why parser.data should be empty. But without seeing the code who can know...

      Comment

      • dbphydb
        New Member
        • Apr 2010
        • 22

        #18
        I tried setting parser.data to a variable and then using that. But its the same and empty string. I dont know why it wont pass :(

        Comment

        • Glenton
          Recognized Expert Contributor
          • Nov 2008
          • 391

          #19
          You basically need to go systematically back debugging it. This is half the job with coding, and why QA is needed! :D

          What is "urlopen(url).r ead()" giving to the DataParser class?

          But, basically, I don't know what your url is giving, and I don't know what your DataParser class is doing, so it's a little difficult for me to help without more info...

          Comment

          • dbphydb
            New Member
            • Apr 2010
            • 22

            #20
            Hi Glenton, I re-structured the code and now its working fine. Thanks for your help!

            Comment

            Working...