FAQ
I write the code here https://gist.github.com/eahydra/5336498

Then, When I parse the
http://static.userland.com/gems/backend/rssTwoExample2.xml XML file, the field
Roll of RssChannel struct is empty, it's parsed failed.

What should I do to solve it?

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

  • Dan Kortschak at Apr 9, 2013 at 6:55 am

    On Mon, 2013-04-08 at 19:45 -0700, Hydra Ea wrote:
    I write the code here https://gist.github.com/eahydra/5336498


    Then, When I parse
    the http://static.userland.com/gems/backend/rssTwoExample2.xml XML
    file, the field Roll of RssChannel struct is empty, it's parsed
    failed.


    What should I do to solve it?
    http://play.golang.org/p/Yewwrg61pL

    Mainly, ensure you include the xml: prefix in the tag string.

    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Volker Dobler at Apr 9, 2013 at 7:01 am
    If you could provide a runable example (stripped down to the
    actual problem) on the playground it would be much easier to
    help.

    If the field is named "Roll" the XML parser looks for a XML element
    named "Roll", but there is no in the sample XML (there is one
    called "blogRoll". Maybe that is the bug?

    V.

    Am Dienstag, 9. April 2013 04:45:10 UTC+2 schrieb Hydra Ea:
    I write the code here https://gist.github.com/eahydra/5336498

    Then, When I parse the
    http://static.userland.com/gems/backend/rssTwoExample2.xml XML file, the field
    Roll of RssChannel struct is empty, it's parsed failed.

    What should I do to solve it?
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Hydra Ea at Apr 9, 2013 at 7:46 am
    Thanks for your advise. I am a newbie. eh, I will use playground later.

    在 2013年4月9日星期二UTC+8下午3时01分25秒,Volker Dobler写道:
    If you could provide a runable example (stripped down to the
    actual problem) on the playground it would be much easier to
    help.

    If the field is named "Roll" the XML parser looks for a XML element
    named "Roll", but there is no in the sample XML (there is one
    called "blogRoll". Maybe that is the bug?

    V.

    Am Dienstag, 9. April 2013 04:45:10 UTC+2 schrieb Hydra Ea:
    I write the code here https://gist.github.com/eahydra/5336498

    Then, When I parse the
    http://static.userland.com/gems/backend/rssTwoExample2.xml XML file, the field
    Roll of RssChannel struct is empty, it's parsed failed.

    What should I do to solve it?
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Hydra Ea at Apr 9, 2013 at 7:46 am
    Thanks for your help.

    在 2013年4月9日星期二UTC+8上午10时45分10秒,Hydra Ea写道:
    I write the code here https://gist.github.com/eahydra/5336498

    Then, When I parse the
    http://static.userland.com/gems/backend/rssTwoExample2.xml XML file, the field
    Roll of RssChannel struct is empty, it's parsed failed.

    What should I do to solve it?
    --
    You received this message because you are subscribed to the Google Groups "golang-nuts" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupgolang-nuts @
categoriesgo
postedApr 9, '13 at 6:43a
activeApr 9, '13 at 7:46a
posts5
users3
websitegolang.org

People

Translate

site design / logo © 2022 Grokbase