Is there a way to get recent articles using JavaScript from Wordpress blog? I need to show some content from the blog easy way on a static page so I think JavaScript would be fine for this.
Asked
Active
Viewed 4,319 times
1
-
This will only work if you're on the same domain. Otherwise no, it won't be fine. – Anders Jul 20 '10 at 07:52
-
Yes, it's just a static html site with a Wordpress blog in a separate folder domain.com/blog. What I need is to place recent entries on the main page of that static site from that blog. – Sergei Basharov Jul 20 '10 at 10:01
1 Answers
1
If you are in different domain, you cannot do this with pure javascript. You will need to use serverside proxy (for example, PHP proxy - a file which will take URL, do request and return data). After you got data, just use jQuery ability to parse XML files and write your HTML.

Community
- 1
- 1

Māris Kiseļovs
- 16,957
- 5
- 41
- 48