Santosh Bhagwat
Santosh Bhagwat

Reputation: 121

How to set site url/base url in wordpress?

I'm new to wordpress, I just install wordpress and want to set my site's base_url. Please any one help me with this. Thanks in advance.

Upvotes: 12

Views: 25545

Answers (6)

Tanmay
Tanmay

Reputation: 31

It is possible to set the site URL manually in the wp-config.php file.

Add these two lines to your wp-config.php, where “example.com” is the correct location of your site.

define( 'WP_HOME', 'http://example.com' );

define( 'WP_SITEURL', 'http://example.com' );

Hope this will help you..

Upvotes: 2

Olexandr Minzak
Olexandr Minzak

Reputation: 176

just insert code

<?php echo home_url(); ?>

for exemple:

<link rel="icon" href="<?php echo home_url();?>/wp-content/uploads/2015/02/logo-symbol-43x43.png" sizes="32x32" />

Upvotes: 4

Full Stack Tutorials
Full Stack Tutorials

Reputation: 205

Follow these steps

  1. After moving your site files (if necessary), log into your your WordPress Dashboard as an administrator.
  2. Next, click on Settings from the menu, and then General, Click on General to get started
  3. The two fields we'll change are WordPress Address (URL) and Site Address (URL).
  4. Enter the URL you'd like to use. For this example, we'll change the two fields to http://dv-example.com.
  5. Scroll down the page and click on the Save Changes button.

Ref link: https://mediatemple.net/community/products/dv/204405334/how-can-i-change-the-domain-name-for-my-wordpress-site

Hope this will help you!

Upvotes: 2

Ganesh Aher
Ganesh Aher

Reputation: 1128

To set urls in your wordpress application just go to Settings tab at left hand side and go to general tab and set site address(url).

Upvotes: 7

Haninder Singh
Haninder Singh

Reputation: 618

In "wp_options" table set "siteurl" and "home" fields value.

Upvotes: 12

Anoxy
Anoxy

Reputation: 953

You can change it in your database table wp_options or in your file wp-config.php like so: https://codex.wordpress.org/Changing_The_Site_URL

Upvotes: 5

Related Questions