- Posts: 2
- Thank you received: 0
Hi. I have a database table called "partners_technology", with the fields: Logo, Company, Country, Expertise. This table is continually added to and logo data is in the format of: /images/partners/technology/logo.png
We need it to show the logo instead of the image path, so I created a view:
CREATE VIEW partners_technology_logo AS
SELECT Logo, CONCAT('<img src="', Logo, '" />') AS image
FROM partners_technology
That created the second table of just the fields: Logo and image; and the "image" data looks correct.
I'm needing to select the "partners_technology" table within the "Table Settings" since that is where all our data is. How can I have it pull the "image" data instead of the Logo data?
Here is a test I'm doing:
www.nomagic.com/partnertest
Thank you!
Please Log in or Create an account to join the conversation.
Hi,
Select all data in the view and than use the view to display it on page.
CREATE VIEW v_partners_technology AS
SELECT *, CONCAT('<img src="', Logo, '" />') AS image
FROM partners_technology
Please Log in or Create an account to join the conversation.
Ha, that was easy!
Thank you!
Please Log in or Create an account to join the conversation.