Adding data for searching in a database using Wordpress

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
sjuaq
Forum Commoner
Posts: 33
Joined: Thu Aug 10, 2017 4:48 pm

Adding data for searching in a database using Wordpress

Post by sjuaq »

Hello,

I have a wordpress instalation that i would like to modify but i don't know how.

Basicaly is a wordpress instalation that i want to use the internal search engine to query a mySQL or MariaDB database and show results to the user. This database needs a importation of a sql file and an excel formated file. I want to import those 2 databases to the main database from wordpress and make them accessible on the search engine format.

Does it require much work or can it be done instantly?

Thanks for all...
User avatar
Vegan
Forum Regular
Posts: 574
Joined: Fri Sep 05, 2008 3:34 pm
Location: Victoria, BC
Contact:

Re: Adding data for searching in a database using Wordpress

Post by Vegan »

excel formatted data is not in the database so using example.com/s="find it" will not catch it
Hardcore Games™ Legendary is the Only Way to Play™
My site is powered by LAMP
sjuaq
Forum Commoner
Posts: 33
Joined: Thu Aug 10, 2017 4:48 pm

Re: Adding data for searching in a database using Wordpress

Post by sjuaq »

You seem to be an expert on the subject can you provide with a "how to"?
sjuaq
Forum Commoner
Posts: 33
Joined: Thu Aug 10, 2017 4:48 pm

Re: Adding data for searching in a database using Wordpress

Post by sjuaq »

My file is in the following format

name:email:ip

How can i import to SQL?
table "wp_posts"

The method that did convert was changing the : to , and then convert with https://sqlizer.io/
But the wp install corrupted.

Any solutions?
User avatar
Vegan
Forum Regular
Posts: 574
Joined: Fri Sep 05, 2008 3:34 pm
Location: Victoria, BC
Contact:

Re: Adding data for searching in a database using Wordpress

Post by Vegan »

if you convert the excel data into some table and import it into a table on WP, then the database can find the details.

Excel can also be embedded into a WP article, but the search capability is limited to text with the embedded object

https://linux-guru.azurewebsites.net/ha ... -survival/

at the bottom of the article there are 3 posts with embedded excel charts, linked from a bulleted list
Hardcore Games™ Legendary is the Only Way to Play™
My site is powered by LAMP
User avatar
Celauran
Moderator
Posts: 6427
Joined: Tue Nov 09, 2010 2:39 pm
Location: Montreal, Canada

Re: Adding data for searching in a database using Wordpress

Post by Celauran »

sjuaq wrote:My file is in the following format

name:email:ip

How can i import to SQL?
table "wp_posts"
I don't know that you want that data in wp_posts. It's not a WordPress post. Give it a dedicated table.
sjuaq
Forum Commoner
Posts: 33
Joined: Thu Aug 10, 2017 4:48 pm

Re: Adding data for searching in a database using Wordpress

Post by sjuaq »

Adding a new table doesn't reach the scope of the search...
Post Reply