You need to have 2 sets of settings one for if file_exists and one for else:
if ( file_exists( dirname( __FILE__ ) . '/local-config.php' ) ) {
include( dirname( __FILE__ ) . '/local-config.php' );
define( 'WP_LOCAL_DEV', true );
} else {
define('WP_HOME', 'http://localhost:666/projectname/');
define('WP_SITEURL', 'http://localhost/foldername/wordpress/');
}
Related Posts:
- Why do I get the timeout warning?
- What is the best way to customise admin files so they survive future upgrades?
- Verify nonce in REST API?
- Add custom html to last sub-menu item
- Custom taxonomy: same terms, but for different years
- Automatic image renaming based on title
- Manipulating post meta in the customizer
- Can I use $wpdb for my custom tables in the WordPress database?
- How to get input_attrs in the sanitize function?
- Php custom query function assistance
- How can I manage my multiple wordpress websites from main website?
- Change from /wp-admin/ to something else?
- How do I deque the default stylesheet?
- Allow comments without approval for custom content type
- Add ‘Right Now’ widget to custom dashboard
- Naming script handles right way
- How to edit pages after installing WP
- Exclude custom taxonomy tag from loop
- User Roles Not Sticking
- Login form in popup
- Replace “WordPress” word in title of Dashboard
- Multiple WordPress outside wordPress installation?
- WordPress generated links – menus and home_url() – not using https despite settings
- WordPress custom login page
- How to use
- How do you modify the WordPress directory structure?
- Change WooCommerce product price based on category and GEO IP country
- Gallery IDS and Captions: hide/show on a per ID basis
- How to check if a custom user profile field is empty
- Properly customizing login/register form
- Updates for a private theme
- Hi, I wanted to make custom search with multiple fields
- Contact From 7 Custom Validation Issues
- How to add an extra button on woocommerce shop page and use it to send the product info with image in a mail? [closed]
- Control Content On Non-Blog Pages
- education system [closed]
- Search widget will search everything in the site, how to limit to only search gallery name
- custom post type – page template
- How to add custom control to a page?
- Navigation label for page in custom theme
- Auto login from custom registration form
- How to get Related Custom Posts?
- Background image not appearing
- How to hook up search results page to a back-end page?
- custom upload directory only for plugin uploads
- Is it possible to change the structure of the HTML generated by the_content()? If yes, how? If not, is there a workaround?
- A truely custom login page?
- How to define custom links in WordPress
- Display specific Taxonomy Term from Custom Post Type
- Widgets won’t save
- Is it advisable to use `add_rewrite_rule()` to serve a custom page?
- Customizing the Widget content markup
- What is the best way to modify Admin Panel on WordPress?
- How to customize shipping region/states on WooCommerce
- Add the site’s name as prefix when adding new users? Multisite
- How do I create a root link in wordpress to a PDF file?
- Upload a web module (html and JS) to wordpress
- How to remove Customizer’s Section and move Control straight to Panel using Child Theme
- Centering one product on a single page [closed]
- Remove link from page title
- Localhost wordpress access remote db wordpress website
- add_action does not work when instance multiple tab-containers via template-file
- Custom RSS feed – blank page
- Customizing admin look and feel for just one particular type of user
- Display Images with More Fields yes / no
- How to query term_id of a Custom Taxonomy by name
- accessing monthly archive from dashboard
- WordPress 3.1.2 Bug: add_theme_support() and video post format registering twice
- WordPress 3.1 update has reversed my blog posts
- Different profile page by role
- WordPress menu: How to make www.link.com/#name never contain current_page_item class?
- 2.9 to 3.0: Pros and cons of upgrading?
- query_posts meta_key with current date
- Get custom field value from not-current page
- RSS feed showing deleted post
- Custom page template, not acting as page
- How to show parent taxonomy using get_the_terms?
- No plugin populate user information in to form
- Best practice to generate token for email action
- how to change the url rediction of the woocommerce login page of the flatsome theme for my own in wordpress?
- My list of terms of custom taxonomy displays 7 times
- Can’t do a src to node modules folder
- Woocommerce – Remove cart button depending product (post) status
- Login CSS style doesn’t load instantly
- How to customize WordPress vertical menu?
- Query Posts to display all posts with category “custom field value”
- Trouble getting started in wordpress – my experience isn’t in wordpress.
- How do I display entries in the top menu based on conditions selected in the sidebar menu?
- Redirect Every Instance of The Author Template Pages to Custom Author Pages
- Customizer API and pages
- Editing a theme’s templates
- How to setup a taxonomy that can have only one post assigned to it?
- How to delete orphan userdata from array in wp-options
- Page template with custom html fields inside a content
- Custom Style per Post, How to Display Custom-Styled Single post on Homepage?
- Twenty Eleven theme, how to change style to a specific “format”
- How to move menu next to left of the search box?
- how to manage Session in WordPress using custom login?
- User Query Multiple Orderby Clause
- Create a page for each database table entries