Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #74994
| References | <CAGxOggEanm=FmXLgcP4tRuwSzvURANeNtShZbFxeGKMSSXZAmA@mail.gmail.com> <slrnlsslu3.a0j.memilanuk@machin-shin.milanuk.lan> |
|---|---|
| Date | 2014-07-22 14:53 +0200 |
| Subject | Re: Removing xml element and strip extra space |
| From | varun bhatnagar <varun292006@gmail.com> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.12180.1406033623.18130.python-list@python.org> (permalink) |
[Multipart message — attachments visible in raw view] - view raw
Hi, Thank you so much for the suggestion. I tried using the rstrip() function but that did not work. Still getting a blank space between *<nodePeriod>* and *</nodeInfo> *as mentioned in the above output xml file: *<nodePeriod nodeTime="600000000"/>* * </nodeInfo>* Is there any other way through which this can be achieved? Can't this be handled by xslt itself in some way? Thanks, BR, Varun On Tue, Jul 22, 2014 at 2:23 PM, Monte Milanuk <memilanuk@invalid.com> wrote: > On 2014-07-22, varun bhatnagar <varun292006@gmail.com> wrote: > > I want to strip the space between *<nodePeriod>* and *</nodeInfo>* > > Can anyone suggest a way out to do that? > > Look at str.rstrip() - by default it removes trailing whitespace > including carriage returns. > > -- > https://mail.python.org/mailman/listinfo/python-list >
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Re: Removing xml element and strip extra space varun bhatnagar <varun292006@gmail.com> - 2014-07-22 14:53 +0200
Re: Removing xml element and strip extra space Tim <jtim.arnold@gmail.com> - 2014-07-22 06:00 -0700
Re: Removing xml element and strip extra space varun bhatnagar <varun292006@gmail.com> - 2014-07-22 15:42 +0200
Re: Removing xml element and strip extra space Monte Milanuk <memilanuk@invalid.com> - 2014-07-22 17:39 +0000
csiph-web