HTML5 Data Bindings Support Product Page
Answered
How to reference database value within PHP code itself?
Asked 17 Jul 2015 01:48:44
1
has this question
17 Jul 2015 01:48:44 Windy City posted:
I'm working on a page that uses HTML5 Data Bindings for my MySQL database. How do I go about referencing/testing a database values from within PHP code itself? I see that I can use provided {{Variable}} placeholder elsewhere on the page to insert my data in HTML. But it doesn't work when I try to test database variables in PHP itself. Any help with the right coding and syntax would be great!Sorry if this is a basic question. I've worked in ASP but finally moving over to MySQL.
Replies
Replied 17 Jul 2015 07:28:27
17 Jul 2015 07:28:27 Teodor Kuduschiev replied:
Hello,
You cannot use the databindings variables inside PHP code.
DMXzone Data Bindings variables are being rendered client-side, while PHP code is being executed server-side. You cannot mix them.
You cannot use the databindings variables inside PHP code.
DMXzone Data Bindings variables are being rendered client-side, while PHP code is being executed server-side. You cannot mix them.
Replied 19 Aug 2015 07:53:22
19 Aug 2015 07:53:22 Jim Elliott replied:
I have got around this by purchasing a class "smplPDO" from CodeCanyon.net for $5. One of the best purchases ever.
It becomes as simple as:
$myvar = $db->getvar('mytable',array('filterfieldname'=>filterfieldvalue),'fieldname');
There is a load more in it as well!
It becomes as simple as:
$myvar = $db->getvar('mytable',array('filterfieldname'=>filterfieldvalue),'fieldname');
There is a load more in it as well!
Replied 04 Apr 2024 13:29:59
04 Apr 2024 13:29:59 Alex T. replied:
I realize JavaScript can be daunting, but fear not! At DoMyCoding.com, we specialize in making JavaScript learning accessible and enjoyable. Our platform offers exhaustive resources and expert guidance to help you master JavaScript programming. From fundamentals to advanced concepts, DoMyCoding.com is your go-to destination for all things JavaScript. Start your coding journey with confidence today
Replied 17 Apr 2024 00:30:53
17 Apr 2024 00:30:53 Zorro Crash replied:
There are a lot of scammers on the Internet but there are still some trustworthy and reliable services that can help you with writing letters. Personally I want to recommend you this https://justdone.ai/ai-recruitment/offer-letter-generator If you need their help, you can write to them at any time as they are available and in case you have any questions about something - you can do it and believe me, they will answer you very fast. If you have any problems - write here.