WSN Links
Featuresspacer Showcasespacer Reviewsspacer Demosspacer Purchasespacer Manualspacer Support

Register | Forgot Password
Flat-file databases
Flat-file databases
By Paul

If you're importing from Gossamer Threads Links 2.0 or Duncan Carver's Link Management, you can do this directly and simply... see http://scripts.webmastersite.net/wsnlinks/index.p... to download the importers for those.

To import from any other sort of flat file database, go to Admin Panel -> Additions -> Import and select the flat-file option. You will need to specify the format of the file where it asks. Open the file in a text editor and deduce what the file is using to separate links from each other, and fields within the link. Then take note of what order the fields are in, starting with the number 0, and type the numbers where your admin panel asks.

The most common flat-file import may be CSV -- you can import any spreadsheet by saving it as a CSV and using this importer. For a CSV the value separating links is the line break character, \n, and the value separating fields is a comma (,).

You can include custom fields in your import by modifying the import template (Admin Panel -> Templates -> Manage Templates -> Admin CP Templates -> Import). Find
<br>Type: <input type="text" name="typeloc" size="5" value="{TYPELOC}">
in there. Copy that line, but change "type" to the name of your custom field in the name and value attributes. For example if you want to handle a field named "company" you should add this to that spot in the template:
<br>Company: <input type="text" name="companyloc" size="5" value="{COMPANYLOC}">
. Repeat for as many custom fields as you want.

If you're importing a very large number of items you may find that the page times out. If so you'll need to cut your file into parts and do one part at a time.

Be sure to regenerate counters after you finish importing.

Rating:


2/5 based on 4 votes. The median rating is 1.

Submitted: 10/05/06 (Edited 03/04/08)

Description: Importing from a text file of data.

Views: 831 views. Averaging 1 per day.
In the most recent 30 day period, there've been 1 views.

Previous Article | Next Article

Home    |    Features    |    Showcase    |    Reviews    |    Demos    |    Purchase    |    Manual    |    Support