Skip to content
Advertisement

how to make a query with database as a variable

I have two databases – lorem and nts.lorem – and need to operate with both of them

JavaScript

everything works fine until db is a variable in an ajax request – for example:

js

JavaScript

php

JavaScript

any help?

Advertisement

Answer

Choose connection according to $db value:

JavaScript
User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement