Dotclear

Vous n'êtes pas identifié(e).

Annonce

13 février 2024 Sortie de Dotclear 2.29

#1 2008-08-11 18:36:28

novica
Membre
Inscription : 2008-08-11

import feature in Dotclear 2

Hi,

I'm trying the import feature in Dotclear 2 and it seems to work partially with an atom feed from aether (http://www.logarithmic.net/pfh/aether).

I can successfully import the feed with the default 10 entries.

The problem, however, is that whenever I try to import the whole feed I get an error saying that no content was imported.

Is there any way to find out what is the error with this and how to fix it?

Thanks!

Novica

Hors ligne

#2 2008-08-11 19:22:00

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

Hey,

could you give us an example feed you're trying to import?

As you just said, 10 entries is the default for many weblogs; is there an option with aether feeds to set the amount of articles you want to display from the feed? My question is: how did you get this error message ("no content was imported")?


Pierre

Hors ligne

#3 2008-08-11 21:37:54

novica
Membre
Inscription : 2008-08-11

Re : import feature in Dotclear 2

Hi Pierre,

So, the exact error message is:

Errors:

    * No entry content


I didn't remember it correctly the first time. And I get this message when I try to import the whole feed (about 350 posts).

The URL of the feed is http://www.softver.org.mk/novica?action … me=1;name=

This is the same URL for importing the default 10 posts. In order to get the whole feed I set an option in aether. I can set the length of the feed to any number of posts.

Hors ligne

#4 2008-08-11 22:01:14

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

Hm... I know there are some import problems with some database systems, and the Dotclear team suggests to reduce the amount of imported items at once.

Can you try to import more and more feeds to check out the limit? Like you try to import 20, then 40, then 80... just to check if this is a number limit or something like this...

If this is a number limit, is it possible, using aether, to display the feed with articles from 0 to [i][b]n, then from n+1 to 2n, then from 2n+1 to 3n, etc.? This is boring, but it should work...

If not... you may consider to switch into super-geek mode, and split the real RSS feed into several "fake" files that you will give one by one as a reference to Dotclear2... dunno if this would work, but it's an idea...


Pierre

Hors ligne

#5 2008-08-11 22:02:28

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

Sorry for the [i][b]n, it's a markup mistake I can't edit!


Pierre

Hors ligne

#6 2008-08-11 22:22:51

novica
Membre
Inscription : 2008-08-11

Re : import feature in Dotclear 2

There is some limit around 80, but I can't get feeds from 81 and so on.

If this limit is something defined in the code, maybe some of the developers can point me to it, so I can change it and see what happens?

Hors ligne

#7 2008-08-11 22:38:43

olivier
Administrator
Inscription : 2004-10-11

Re : import feature in Dotclear 2

Hi novica and welcome :)

The only limit is the amount of time and memory your PHP process can consume importing your feed. It seems that after 80 entries, there's to much data. A solution could be :

- import ~80 entries
- set them offline on your old blog
- import again ~80 entries
- and so on :)


La seule difference entre un fou et moi, c'est que je ne suis pas fou. (Dali)

Hors ligne

#8 2008-08-11 22:42:37

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

Clever idea... much better than hacking a fake RSS file, actually :)


Pierre

Hors ligne

#9 2008-08-12 06:20:40

novica
Membre
Inscription : 2008-08-11

Re : import feature in Dotclear 2

olivier a écrit :

The only limit is the amount of time and memory your PHP process can consume importing your feed. It seems that after 80 entries, there's to much data. A solution could be :

- import ~80 entries
- set them offline on your old blog
- import again ~80 entries
- and so on :)

Hi Oliver,

Thanks for the tip. Unfortunately there is no "set offline" option in the script I'm using at the moment - only "delete". :)

Anyway, I set up the memory limit to 128M, then to 256 in php.ini, the time limit also... still get the same error.

Oh well, I just might start with a empty dotclear. :)

Hors ligne

#10 2008-08-12 07:20:32

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

Then you should try my method:

1. set aether to display every single article in the feed;
2. save this feed as an XML or HTML file on your hard drive;
3. split it manually into as many files as needed, each file should include the header (if any) and ~80 articles (hopefully you don't have 5000 articles, though!);
4. upload the files you've created on your website, and try to import these files using the Dotclear feed import option.

I hope it will work for you!


Pierre

Hors ligne

#11 2008-08-12 07:27:35

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

I just checked the feed you provided, and here are some info (but I guess you knew it already):

- the header is the following:

<?xml version="1.0" encoding="utf-8"?>
<feed version="0.3" xmlns="http://purl.org/atom/ns#">
<link rel="alternate" type="text/html" href="http://www.softver.org.mk/novica/"/>

<title>airborne</title>
<modified>2008-08-11T12:56:01Z</modified>
<tagline>airborne: in or carried by the air.</tagline>
<author><name>?????? ?????</name><email>nnovica@xxx.com</email></author>

- every article is wrapped into an "entry" tag like this:

<entry>
    <title>Article title</title>
    <issued>2008-08-11T12:56:01Z</issued>

    <modified>2008-08-11T12:56:01Z</modified>
    <id>http://www.softver.org.mk/novica/01218459361</id>
    <link rel="alternate" type="text/html" href="http://www.softver.org.mk/novica/01218459361"/>
    <content type="text/html" mode="escaped">
        Article content
    </content>
</entry>

Pierre

Hors ligne

#12 2008-08-12 13:23:03

novica
Membre
Inscription : 2008-08-11

Re : import feature in Dotclear 2

Pierre,

Slicing up the rss did the trick. And I actually found the problem regarding the No entry content error. :)

I have a post with just a title and no body... so the <content> tag is empty and that broke the import all this time.

Now I have to move the non-blog content and I'm running on DotClear.

Thanks for all the help!

Hors ligne

#13 2008-08-12 13:55:47

Pierre
Membre
Lieu : Taipei, Taiwan
Inscription : 2004-11-15

Re : import feature in Dotclear 2

\o/

Glad you finally discovered the problem :) This bloody XML stream always need to be perfectly valid... this is so different from HTML! :)

Now you can enjoy Dotclear!


Pierre

Hors ligne

Vous n'êtes pas identifié(e).

Pied de page des forums

Sites map