| 12 |
INSTALLATION |
INSTALLATION |
| 13 |
1. put the advogato_import directory to your modules directory |
1. put the advogato_import directory to your modules directory |
| 14 |
2. import the mysql table structure |
2. import the mysql table structure |
| 15 |
3. activate the module |
3. activate the module at "administer>modules" |
| 16 |
4. configure the module |
4. configure the module at "administer>settings>advogato_import" |
| 17 |
|
5. users can then queue node imports in "my account>advogato_import" |
| 18 |
|
|
| 19 |
AUTHOR |
AUTHOR |
| 20 |
David Kent Norman |
David Kent Norman |
| 23 |
|
|
| 24 |
ADDITIONAL NOTES |
ADDITIONAL NOTES |
| 25 |
I created this script for a one-time run of importing my own diary. |
I created this script for a one-time run of importing my own diary. |
|
I don't really intend to provide any more development on this module. |
|
| 26 |
|
I don't intend to provide any more development on this module, |
| 27 |
|
so if you're a developer itching to make a change, go ahead. |
| 28 |
|
|
| 29 |
|
To delete the entries from Advogato after you import them, I copied |
| 30 |
|
Drupal's xmlrpc.php file, put the following to the top it, and ran it |
| 31 |
|
at a command prompt with `php -q xmlrpc.php`. It is not implemented |
| 32 |
|
in the automated part of this module for the obvious data |
| 33 |
|
distruction if something goes wrong. |
| 34 |
|
|
| 35 |
|
<?php |
| 36 |
|
set_time_limit(0); |
| 37 |
|
$username = 'deekayen'; |
| 38 |
|
$password = 'my_password'; |
| 39 |
|
$len = (int)xmlrpc('http://www.advogato.org/XMLRPC', 'diary.len', $username); |
| 40 |
|
$cookie = xmlrpc('http://www.advogato.org/XMLRPC', 'authenticate', $username, $password); |
| 41 |
|
for($i = 0; $i <= $len; $i++) { |
| 42 |
|
echo xmlrpc('http://www.advogato.org/XMLRPC', 'diary.set', $cookie, $i, ' '); |
| 43 |
|
} |