Due to run-time restrictions, an export must be sequentially callable.
For this purpose, a start URL must be provided. The next URL to be called is indicated by Location
-Header (HTTP location).1)
This redirection is followed until a Location
-Header is no longer returned.
For the incremental export, certain parameters of the Export-URL are supplied.
start
limit
shopkey
language
Possible outputs in the body of the script may include:
SUCCESS: Unfinished
: The export is not complete yet; forwarding will occur to the next call.
SUCCESS: Finished
: The export has been correctly completed.
FILE: <PATH_OF_THE_CSV>/<NAME_OF_THE_CSV_FILE>
: Output of the (absolute) path and file name (without domain).
ERROR
, <error message>
: An error has been found.
The item data is being exported to a CSV file according to a corresponding format.
The file name has to be put out after the export (see example below).
The CSV file has to be created in the usual directory for exports that is defined in the shop system or (if not available) in the export path, which is set in the shop-backend.
The name of the CSV has to be comprised as follows:
findologic_<shopid>_<language code>.csv
If there is no subshop function in the shop system, i.e. if only a main shop is being used, the default value for the shopid
is 0
.
The main shop is being exported in german language:
http://www.mein-shop.de/export/findologic_0_de.csv
A subshop with ID 2 is being exported in English:
http://www.mein-shop.de/export/findologic_2_en.csv
http://www.example.com/findologic_export.php?start=0&limit=100&language=de&shopkey=ABCDABCDABCDABCDABCDABCDABCDABCD
limit
parameter.start
parameter (0-based).CSV-file
.HTTP/1.1 302 Found Location: http://www.mein-shop.de/findologic_export.php?start=100&limit=100&language=de&shopkey=ABCDABCDABCDABCDABCDABCDABCDABCD ... SUCCESS: Unfinished
start
parameter is the respective value of the last start
parameter plus the value of the limit parameter.limit
parameter remains the same.HTTP/1.1 200 OK ... SUCCESS: Finished FILE: <PFAD_ZUR_CSV>/<CSV_DATEINAME>
CSV
just created is imported by Findologic.
http://www.example.com/findologic_export.php?start=0&limit=1000&language=de&shopkey=ABCDABCDABCDABCDABCDABCDABCDABCD
HTTP/1.1 302 Found Location: http://www.example.com/findologic_export.php?start=1000&limit=1000&language=de&shopkey=ABCDABCDABCDABCDABCDABCDABCDABCD ... SUCCESS: Unfinished
http://www.example.com/findologic_export.php?start=1000&limit=1000&language=de&shopkey=ABCDABCDABCDABCDABCDABCDABCDABCD
HTTP/1.1 200 OK ... SUCCESS: Finished FILE: findologic_1_de.csv
The export script can also be in a .htaccess-protected area. For this purpose, you can store a user name and password in the Findologic customer account under Settings → Import/Export → Export Settings.
If you use load-balancing in your infrastructure, please ensure, that export calls are always forwarded to the same host or to a host that is outside the cluster. Otherwise the export cannot be completely generated because of the redirect chain.