Create posts in bulk with custom fields via CSV import

In this example, we will show you how you can exploit smart_seo_import_update to easily create posts/pages in one go via CSV import. First off, let’s prepare our CSV.

Here, we will create a post with location as post type with the following custom fields:

  • address
  • suburb
  • coordinates
  • phone

Your CSV may look like this:

0locationBP Beeliar701 Beeliar Dr, Cockburn Central WA 6164Cockburn Central-32.1273058,115.8412204(08) 1234 5678
0locationIGA KinrossKinross Central Shopping Centre Cnr Selkirk Ave &, Connolly Dr, Kinross WA 6028, AustraliaKinross-31.7183214,115.7393733+61893049748
0locationMalibu Fresh EssentialsUnit 9 Malibu Rd, Safety Bay WA 6169, AustraliaSafety Bay-32.303732,115.7421268(08) 1234 5678
0locationIGA Kingsley100 Kingsley Dr, Kingsley WA 6026, AustraliaKingsley-31.8079966,115.7876127+61894097088

Add below’s code in your theme’s functions.php file:

Was this page helpful?