Import IP Addresses from CSV array error
phpipam open-source IP address management
Brought to you by:
myha
Hi,
when I try to import IP Addresses from CSV the show addresses works correctly but when I confirm to import I receive an PHP error but phpipam shows "Import Successfull".
The PHP error is: Cannot use a scalar value as an array in /var/www/html/app/subnets/import-subnet/import-file.php on line 100
The IPs are created but are somehow "bugged" (see attachement)
Anonymous
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
This seem to be 2 different issues - when I use the xls template I dont receive the PHP error but I still have the problem that the added IPs are added with a zero at the end and are not recognized as part of the subnet (not marked in green or effect the pie chart)
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
After trying to narrow the issue I discovered that the insert process is actually fine.
My assumption was that the conversion of the IP is somehow wrong and therefore shown with a tailing 0. I was not aware that this 0 indicates the "state".
The problem is a mistake in the documentation. The insert IP address popup shows the state "Active" but this state does not exist (anymore?). When I changed the state to "Used" the import worked correctly and did not show the confusing 0 anymore.
Guess this can be closed.
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
I am having the exact same issue, my csv file looks fine.
I'm no developer but found that I had to include all information in the import file.
If you dont have any data for that field have a , (comma) to hold the field. That goes for all 9 fields.