Questions tagged [csv]

Comma-separated values or character-separated values: a text format to store tabular data. Often used to import or export MySQL tables.

Filter by
Sorted by
Tagged with
0 votes
1 answer
53 views

Why is there a bunch of WordPress HTML code in my browser CSV download?

I'm trying to add a button/link to an existing WordPress page to allow downloading a dynamically created CSV file. The contents of the CSV file are retrieved from the WordPress database. Unfortunately ...
bistromatic's user avatar
0 votes
0 answers
71 views

Wordpress Custom Post type csv exporter

I'm trying to export custom post-type data csv but it exporting blank CSV file, where is the wrong public function export_result_entry_csv(){ $data = $_POST['data']; $args = [ 'post_type' =&...
Nayeem Farid's user avatar
0 votes
0 answers
81 views

How to set an exact search box in tablepress plug-in

I installed TablePress and set a table that contains 20 rows and 3 columns. I want to let people to search an unique digit number from a column and show the result as value of the same row or three ...
I'mALittleBus's user avatar
0 votes
0 answers
153 views

is it possible to use wp cli to export custom post types

i have been trying to use WP CLI to export custom post type 'product' from custom taxonomy 'product_brand'. however, my command is exporting a random list of products, from other brands. it also is ...
challenge2022's user avatar
0 votes
0 answers
133 views

Creating posts with php-script + csv

I'm trying to create posts with a Script + CSV. Each row schould create a post, while each column should fill the title/ACF-Fields. $csv_file_path = '/test.csv'; function create_wp_cpt_from_csv() { ...
Dave's user avatar
  • 1
0 votes
0 answers
58 views

Import users and custom user meta from csv

I need to create some users by importing the basic user info and the wp meta from a csv file. I will need to map some custom user meta values I have into the csv during the import. I'm thinking to ...
devdev's user avatar
  • 1
0 votes
0 answers
58 views

Exporting CSV of users with custom user taxonomies out of Wordpress

I'm trying to export a CSV or XML out of a WordPress site that has custom taxonomies added to the users. The site I'm working with adds custom taxonomies following the format here. Plenty of export ...
PHS's user avatar
  • 61
0 votes
0 answers
187 views

Exporting a form to a CSV file does not work in WordPress but it does in PHP

I have a form with some fields that I need to implement in a WordPress template. If I do it in vanilla PHP it works but when I put it in a WordPress template it doesn't work, can it be a problem with $...
JamalDols's user avatar
  • 101
0 votes
1 answer
397 views

Create a form with custom autocomplete address field and CSV import values

I want to create a contact form with 2 sections. The first section includes an address field. I have a repository of 100,000 addresses in CSV format. I need to import all addresses into the address ...
Samuel's user avatar
  • 324
0 votes
0 answers
141 views

Custom database table and custom search

On an existing site I am migrating from there is a csv file (about 5000 rows) and a Perl script that presents the user with a simple search form to display a selection of the fields on a search ...
Packwood's user avatar
  • 101
0 votes
1 answer
214 views

Updating Custom Posts via CSV Import

I'm writing a plugin so i can regularly upload CSV files to update data in post metas. The problem is that the order of the columns sometimes change with each CSV file i am supplied with. The code i ...
agxer's user avatar
  • 1
0 votes
0 answers
264 views

How to fetch csv file and show in shortcode

I am missing a simple method to fetch data (every 30 minute) from a public Google Sheet CSV file and show the data with a shortcode in WordPress - can I do that with a php snippet in functions.php and ...
Jon Doe Anderson's user avatar
2 votes
1 answer
803 views

Exporting table to csv works in the admin but exports HTML data when used on the front end

I have some code, implemented by a shortcode within a custom plugin. The code generates a CSV file from some data tables. When I run the shortcode within the admin section, it works perfectly. BUT ...
Debbie Kurth's user avatar
0 votes
0 answers
734 views

best way to upload a large file to wordpress using wp all import

i am trying to import a csv file that has 50,000 entries to woo commerce. i am using wp all import plugin. now i know there are certain criteria that can be met to speed up the process however having ...
user2962748's user avatar
1 vote
1 answer
54 views

code is working properly in Core PHP but writing coding in WordPress

function generate_pdf($array) { header('Content-Type: text/csv'); header('Content-Disposition: attachment; filename="sample.csv"'); $fp = fopen('php://output', 'wb'); foreach ( $array ...
Mr_Ussi's user avatar
  • 36
0 votes
1 answer
451 views

Create users by importing from CSV, with User ID assigned from CSV

I am in a situation where I need to import user data from another platform. Because, I have to keep associated userID for some reason, I have to keep user id as it is in the csv. I have tried using ...
pixelngrain's user avatar
  • 1,390
1 vote
0 answers
329 views

CSV syntax for WP All Import upload without ACF

I need to import listings into the Listeo theme of Wordpress using WP All Import plugin. All works fine, however, I am unable to import values for custom fields which have a type of Checkbox. I've ...
sergekol's user avatar
0 votes
0 answers
292 views

How to send a particular csv file as an email?

I have created a function to run a query and create a CSV file. The CSV file will be stored in a particular folder on my server. These files are distinguished by dates. I want to schedule an event ...
Nirmal KUmar's user avatar
0 votes
0 answers
225 views

How do I export categories, site stats, comments and posts from wordpress to excel

I need to export the posts, categories, the author, the page views and comments from WordPress to excel. This is because I need to analyze the performance of each author and each category based on ...
user8953638's user avatar
0 votes
2 answers
585 views

How to return/export only data showing on screen in custom post type view all screen

If I for example filter my custom post type by date and it only shows 2 records on screen, I only want to export those 2 records, but it is exporting a bunch of records out of my control ie: the wrong ...
user10980228's user avatar
0 votes
0 answers
749 views

Why is that only the first row getting inserted into Mysql table when i import csv file on backend custom plugin?

I am experimenting with bulk import from csv file for my plugin. As I am new to plugin develpoment, please guide me if I am doing something wrong. What I have: I have 4 columns of multiple rows in a ...
Savio menezes's user avatar
3 votes
1 answer
660 views

Export User Info to CSV from Front End

Trying to export to CSV from WordPress front end. Here is what I have so far. I was able to export to CSV from the admin area, but for some reason I am unable to export from the front end. What am I ...
Michael's user avatar
  • 281
1 vote
0 answers
117 views

How to retrieve current wordpress profile page URL?

I'm trying to allow users to export their own profile info to a CSV using a link on their profile. Everything works except the $url path of the link. Here's what I have: $url = $_GET['uri']; $nonce = ...
Michael's user avatar
  • 281
1 vote
0 answers
147 views

Cron job update csv, need help solving :-)

Okay so my question is as follow: I have a big csv file containing alot of products ranked after id, price, stock etc, this file updates every hour via a link. On the other hand i have a csv file ...
Lucas Hunt's user avatar
0 votes
1 answer
306 views

Upload advanced custom field text link array with csv

On my webshop I have to see a button with a link to ad pdf file. For every product that button need to have a different link and a different button title name. I built the webshop with woocommerce ...
NielsD4's user avatar
0 votes
0 answers
288 views

Export Wordpress User Meta to CSV/Excel

I have shops and consultants both set up on Wordpress as users with different roles. I want to include an "Export" link on the consultants' profiles using a shortcode that will export the shops on ...
Michael's user avatar
  • 281
0 votes
1 answer
226 views

Creating categories while importing via CSV

I have a CSV that I am importing via a custom plugin I made. This will create a CPT that has a few ACF fields. This CPT is called Formula, and it has a taxonomy associated with it called formula_type. ...
Aaron's user avatar
  • 101
0 votes
1 answer
21 views

Page is loading after submit before the file is processed

I have built a user import page that imports via csv file upload. The issue I am having is that the page is loading before all of the rows (user information) is finished processing/ inserting users. ...
gray's user avatar
  • 1
0 votes
1 answer
400 views

help with really simple csv importer

( sorry for the title, but i dont know how to explain this as a title ^^ ). I'm using really simple csv importer to bulk import data in my site, using Advanced custom fields. So i need to import ...
Gregory's user avatar
  • 584
0 votes
2 answers
1k views

Export to csv adding html to file

I am trying to export results to a csv file using the following code. The export appears to work, but when I open the file, it contains the html code from the page. Any help is appreciated. ob_start()...
Darth Mikey D's user avatar
0 votes
1 answer
757 views

How do I get data from my database into my Custom Export Field

I am trying to get data from my database to export to a XML or CSV File by using a custom query. This is my function with the query : <?php function get_workhours($ID){ $sql = $wpdb->...
TerribleADC's user avatar
0 votes
1 answer
1k views

How can I reference external attachments without breaking core WordPress files?

I am developing a site that uses WooCommerce & WordPress to show a fair amount (10,000+) products, and can't accommodate the size of all the images for the products. So, I'm leaving the images on ...
Brettins's user avatar
  • 101
0 votes
1 answer
2k views

Can't upload CSV file to plugin directory using custom upload form in admin panel

I need some assistance here. So far, i build a plugin, that are able to import data of a CSV file and parse it into fields of a custom post type. At this point, I would like to make a form to ...
Dougless's user avatar
1 vote
1 answer
2k views

How do I update a field of a meta box?

While parsing data from a CVS file into a custom post type, i would like to parse data into the fields of a meta box, that I created. The meta box fields are normally updated like this: function ...
Dougless's user avatar
0 votes
0 answers
235 views

Unable to update the meta boxes with multiple fields

I successfully build a function, that is able to import data from a CSV into posts of a Custom Post Type (CPT). I am able to parse data into the native Title and Description fields, but it fails, when ...
Dougless's user avatar
0 votes
0 answers
122 views

Updating the database after parsing CSV document

Im trying to update the database based in a CSV document, if the first value in the CVS row is equal or greater than 300, it should update the database, and so on....but I cant get it to work, the ...
Mefistofeles 's user avatar
0 votes
2 answers
959 views

Query a custom taxonomy in a function to create an csv file

I a problem with getting the query for custom taxonomy to work in this function. The $filter is filled with data but the get_posts() does not use it? The query works without the tax_query and there ...
Jesper's user avatar
  • 11
0 votes
1 answer
1k views

Undo WooCommerce CSV import

I've done a CSV import through the WooCommerce import function. Unfortunately, there's something what went wrong. By now, almost all products don't show any data as it has somehow been overwritten. I'...
Bokdem's user avatar
  • 113
0 votes
0 answers
95 views

How to map data on CSV to web pages?

Like Contact information, descriptions, budget, prices, other numbers, on a CSV or spreadsheet, how to link it to WordPress web page? I'm using cpanel, WordPress, Tablepress plugin, elementor page ...
Altoban's user avatar
  • 101
1 vote
0 answers
649 views

Export Custom Report as CSV

I want to build an admin panel that works like this: User enters a date range and clicks "Show Report". The query results are then displayed in the admin panel. User clicks "Export to CSV" and a CSV ...
Isaac A.'s user avatar
0 votes
1 answer
51 views

Having issue on Loading Meta Data From CSV to CPT

I have a custom post type which has one Title, and two meta box custom fields as $price = isset( $we_productMetas['price_box'] ) ? esc_attr( $we_productMetas['price_box'][0] ) : ''; $color = isset( $...
Mona Coder's user avatar
1 vote
1 answer
1k views

How to Upload CSV Data into Custom Post Type Data with Metabox programmatically

I have a Custom Post Type called movies which had only title enabled from post support and 3 custom field of metabax as box office, year, and director like now I have like 150 rows CSV formatted ...
Mona Coder's user avatar
1 vote
0 answers
184 views

How to make a wordpress site multilingual by uploading a translated CSV file that has the traslations?

I have a website which is in french and i need the website to be read by my users in english too. How do i achieve that without making or creating entirely new pages with english translations. I have ...
pankaj7621's user avatar
1 vote
1 answer
978 views

Importing CSV into database table not working?

global $wpdb; if (isset($_POST["import"])) { $fileName = $_FILES["file"]["tmp_name"]; if ($_FILES["file"]["size"] > 0) { $file = fopen($fileName, "r"); while (($column = fgetcsv($file, ...
Coder Sathya 's user avatar
1 vote
1 answer
97 views

How to handle a CSV with 65,000+ rows and make it searchable?

I have a csv of 65,000+ rows. Each row only has two fields, an ID code and a Description. This csv will get updated every year or so. The users needs to be able to type in the code and get a list of ...
Joel Abeyta's user avatar
0 votes
0 answers
147 views

multiple string replace of post's content for large data

I am trying to replace all player name mentioned into my post's content with related player's profile link. And all the player name and player links saved in a csv file. Example: player one,www....
Souvik Sikdar's user avatar
0 votes
1 answer
150 views

Imported posts for cpt are imported as scheduled, not published [SOLVED]

I'm importing posts to a plugin's custom post type for Stores. As I had roughly 1500 stores to upload, I decided to make it via csv/txt bulk import. I created one post, and exported it to have the ...
atempel's user avatar
  • 93
1 vote
1 answer
3k views

How to export custom database data to excel file

Hi everyone I have the code below, but when I click on the link generated a new page is open with 0 display on it. What I'm doing wrong? function list_reservation_to_csv() { global $wpdb; $...
Francesco Tonti's user avatar
1 vote
0 answers
244 views

Huge category CSV import does not work

I have a 1.5 MB (with about 20.000 line) CSV file and I would like to import this into my new WordPress site. The code below does not create all of the categories, only some of them. I already ...
Alex's user avatar
  • 11
1 vote
0 answers
69 views

Manipulate CSV data during upload, is it possible?

I am generating membership invoices from client supplied membership list CSV. I created a custom post type, and I'm using wpallimport to upload the CSV data into that custom post type. Each row in the ...
AOS Studios's user avatar