Web Wiz - Green Windows Web Hosting

  New Posts New Posts RSS Feed - GetLastTopics bug?
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

GetLastTopics bug?

 Post Reply Post Reply
Author
mtm81 View Drop Down
Groupie
Groupie


Joined: 03 December 2002
Status: Offline
Points: 57
Post Options Post Options   Thanks (0) Thanks(0)   Quote mtm81 Quote  Post ReplyReply Direct Link To This Post Topic: GetLastTopics bug?
    Posted: 16 August 2012 at 3:45pm

I'm using the API to pull in the lastTopics into a different part of the site.
 

If I get a response such as:


<?xml version="1.0" encoding="UTF-8"?>
< ns="@namespace'>http://www.w3.org/1999/">@namespace html url(http://www.w3.org/1999/xhtml); :root { font:small Verdana; font-weight: bold; padding: 2em; padding-left:4em; } * { display: block; padding-left: 2em; } html|style { display: none; } html|span, html|a { display: inline; padding: 0; font-weight: normal; text-decoration: none; } html|span.block { display: block; } *[html|hidden], span.block[html|hidden] { display: none; } .expand { display: block; } .expand:before { content: '+'; color: red; position: absolute; left: -1em; } .collapse { display: block; } .collapse:before { content: '-'; color: red; position: absolute; left:-1em; } <ApiResponse><ErrorCode>0</ErrorCode><ErrorDescription/><ResultData recordcount="2"><Record><TopicName>
<![CDATA[a second test]]>
</TopicName><TopicID>2</TopicID><ForumName>Chat</ForumName><ForumID>1</ForumID><TopicLocked>False</TopicLocked><ReplyCount>0</ReplyCount><EventDateStart/><EventDateEnd/><Thanks>0</Thanks><Answer>False</Answer><Hidden>False</Hidden><PostID>2</PostID><PostDate>2012-08-16 07:21:14</PostDate><MemberID>1</MemberID><MemberName>user</MemberName><MemberIP>000</MemberIP><Post>
<![CDATA[this is a 2nd test for us]]>
</Post></Record><Record><TopicName>
<![CDATA[tester topic]]>
</TopicName><TopicID>1</TopicID><ForumName>Chat</ForumName><ForumID>1</ForumID><TopicLocked>False</TopicLocked><ReplyCount>0</ReplyCount><EventDateStart/><EventDateEnd/><Thanks>0</Thanks><Answer>False</Answer><Hidden>False</Hidden><PostID>1</PostID><PostDate>2012-08-16 07:11:58</PostDate><MemberID>1</MemberID><MemberName>Tes</MemberName><MemberIP>111</MemberIP><Post>
<![CDATA[this is a new tester topic for testing only]]>
</Post></Record></ResultData></ApiResponse>

If I query any part of and invidual record down to EventDateStart I get the info back(so in the case of the above response looking at the first record that would be ReplyCount 0 for example)however Anything in the response past that EventDateStart field doesn't get the response info back.. I get nothing.my code looks like this in my pagE:

If Not thisnode.selectSingleNode("TopicName") IS NOTHING then
    LatestPostHTML = LatestPostHTML & thisnode.selectSingleNode("TopicName").Text
       end if
   
    If Not thisnode.selectSingleNode("ReplyCount") IS NOTHING then
    LatestPostHTML = LatestPostHTML & " (" & thisnode.selectSingleNode("ReplyCount").Text & ")"
       end if

If Not thisnode.selectSingleNode("PostDate") IS NOTHING then
 LatestPostHTML = LatestPostHTML & " (" & thisnode.selectSingleNode("PostDate").Text & ")"
end if

I don't get the PostDate coming through.  I've tried everything past that EventDateStart and nothing...any ideas anyone?
Back to Top
mtm81 View Drop Down
Groupie
Groupie


Joined: 03 December 2002
Status: Offline
Points: 57
Post Options Post Options   Thanks (0) Thanks(0)   Quote mtm81 Quote  Post ReplyReply Direct Link To This Post Posted: 21 August 2012 at 2:20pm
bump...Smile
Back to Top
WebWiz-Bruce View Drop Down
Admin Group
Admin Group
Avatar
Web Wiz Developer

Joined: 03 September 2001
Location: Bournemouth
Status: Offline
Points: 9844
Post Options Post Options   Thanks (0) Thanks(0)   Quote WebWiz-Bruce Quote  Post ReplyReply Direct Link To This Post Posted: 21 August 2012 at 3:40pm
The XML is formatted correctly, so there is no reason why you can not pull data for any part from the XML.

The only thing I can suggest is that you adapt your code to try different ways to return the data. If you are using Microsofts MSXML component, maybe try a different version.
Back to Top
 Post Reply Post Reply

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.08
Copyright ©2001-2026 Web Wiz Ltd.


Become a Fan on Facebook Follow us on X Connect with us on LinkedIn Web Wiz Blogs
About Web Wiz | Contact Web Wiz | Terms & Conditions | Cookies | Privacy Notice

Web Wiz is the trading name of Web Wiz Ltd. Company registration No. 05977755. Registered in England and Wales.
Registered office: Web Wiz Ltd, Unit 18, The Glenmore Centre, Fancy Road, Poole, Dorset, BH12 4FB, UK.

Prices exclude VAT at 20% unless otherwise stated. VAT No. GB988999105 - $, € prices shown as a guideline only.

Copyright ©2001-2026 Web Wiz Ltd. All rights reserved.