Search
 
SCRIPT & CODE EXAMPLE
 

PHP

connect another database in wordpress

function connect_another_db() {
    global $seconddb;
    $seconddb = new wpdb(USERNAME, PASSWORD, DATABASE_NAME, HOSTNAME);
}
add_action('init', 'connect_another_db');
Comment

PREVIOUS NEXT
Code Example
Php :: laravel json response 
Php :: string compare in php 
Php :: laravel 5 use env variable in blade 
Php :: php set title dynamically 
Php :: symfony set content type 
Php :: laravel datepicker date format 
Php :: wp_query post by category taxonomy 
Php :: doctrine query builder order by multiple 
Php :: how to combine variables and text into a string php 
Php :: explode php all values to int 
Php :: call php function in js 
Php :: can we create linked list in php 
Php :: file could not be downloaded: Unable to find the wrap per "https" - did you forget to enable it when you configured PHP? failed to open stream: No such file or directory 
Php :: cronjob php linux 
Php :: php ical 
Php :: replace key in php 
Php :: laravel collection distinct 
Php :: php gethostname 
Php :: php how to connect to db using PDO 
Php :: fast excel export laravel 
Php :: laravel pagination number of items 
Php :: Remove last symbol from string 
Php :: woocommerce php product gallery change to carousel 
Php :: check if value change laravel 
Php :: grouping routes based on controller 
Php :: throwable php 
Php :: model find by certain column laravel 
Php :: check if array is empty php 
Php :: laravel passport vue 401 Unauthorized 
Php :: wordpress is_tag function 
ADD CONTENT
Topic
Content
Source link
Name
3+1 =