Search Query to lookup customer database
Autor: GMR .
Visitado 2094,
Seguidores 2,
Compartilhado 0
I have a list of customers and their information that I made and saved as csv file and had it imported onto my cpanel online as MSQL Database, now I want this to be incorporared to website x5 as a search option where the customer can access to check his information. Is it possible? Please help.
Publicado em
Hello GMR
Yes - and no
In X5 it is possible for customers to see information of their orders. Customers can only see own orders.
It is possible with the database-viewer-object to view data from a table and to search all data in this table - BUT - it is ALL data.
If you want users to see only his own data, and eventually maintain his own data, you must have a database where users are able to log in, and where you can specify for tables which records the user is allowed to view/edit.
For this purpose I could recommend the AppGini database tool : https://bigprof.com/appgini
If it doesn't matter if the users can see each others information, then I will recommend the database-viewer-object :
https://market.websitex5.com/en/objects/live-preview/371262fa-27c5-421a-9127-852da219d4
Hope this helps
Kind regards
John S.
You could also have a protected page for each user.
On each page you have a PHP-script that shows data from the table and where each PHP-script is set to select only data for the specific user that has access to the page where the PHP-script is shown.
You have to make the PHP-script yourself, but there is many examples on the net, that you could use.
It would be the same script for each page - only the select statement should be special for each user.
Autor
Hi John
Thanks for your help. I think the appgini is great but too complex for my needs I think. Can I show what I mean below in pictures.
All I want is a search bar for a customer to enter their account # for example and they will access all of their other informations such as address, phone, etc.
As I said I used MYSQL on Cpanel and imported a csv file with all the information for each customer and now what do I do with this to get it on website X5 and upload to my site for use?
With you second option of protected page for each user, that sounds good but can you assist more in this?
Thanks again.
Hello GMR
I will guide and help, but as this is a custom-code thing, I think the forum is not the correct place for this.
I will suggest you contact me via the contact form here : http://calendarforum.dk/contact.html
If it should end up in something that will be of general interest for the X5 forum, then we could continue here.
Hello GMR,
The answer to your question is here: https://wsx5.afsoftware.fr/viewforum.php?f=110
I have created a plugin to manage the database and his contents. This tool is complemantory and very useful
Enjoy!
Best Regards
https://wsx5.afsoftware.fr