cancel
Showing results for 
Search instead for 
Did you mean: 

Dev site is redirecting, looking for files in FTP

Dev site is redirecting, looking for files in FTP

Can anyone tell me where core_config_data is located for my dev site in the ftp. I assum its under the public_html folder but I can't seem to find it. My dev site randomly started redirecting to the main site and now I can't even login to the backend of the dev site. Thanks!

10 REPLIES 10

Re: Dev site is redirecting, looking for files in FTP

Are you sure that you are not confusing a database table with an FTP path? In Magento database there is a table called `core_config_data` and it contains configuration details like store 'base_url' and many-many others...

-------Store Manager for Magento 1.x and 2.x - enhances the functionality of default admin web interface, speeds up inventory management, automates daily tasks.

Re: Dev site is redirecting, looking for files in FTP

I am most definitely confusing the two then. Where is the table located in Magento? I'm not familiar with these. Thanks!

Re: Dev site is redirecting, looking for files in FTP

http://www.w3schools.com/php/php_mysql_select.asp

 

select * from core_config_data;

 

these config values are mostly configurable in magento admin system->configuration page, url is controlled in system->configuration ->web->unsecure/secure

Re: Dev site is redirecting, looking for files in FTP

Go to phpMyAdmin (if your hosting provides it). There click Databases in the top ribbon. Then click on your store database. You should see a LONG list of tables. Hit Ctrl+F in your browser and type core_config_data. Once found - click on the table. Now you should see data in that table with ability to select-copy-paste and Inline Edit. At the bottom you should see a paginator, that allows to show 30 or 3000 rows per page, you might want to use it.

 

P.S. It is always a lovely idea to backup the database before playing with it.

-------Store Manager for Magento 1.x and 2.x - enhances the functionality of default admin web interface, speeds up inventory management, automates daily tasks.

Re: Dev site is redirecting, looking for files in FTP

Thanks! I ended up figuring out how to find the database. I changed the secure/unsecure back to the dev.website.com name but it still redirects. I tried the solutions listed here but nothing has helped. Any ideas?

Re: Dev site is redirecting, looking for files in FTP

1. Make sure that it's not DNS issue

 

Maybe someone added a rule into zone file to redirect all subdomains (*.example.com) to main domain (example.com).

 

2. Make sure it's not VirtualHost issue

Redirect also might have been done with virtual host in apache configuration that redirects specific ServerName (dev.example.com) to specific folder on server (main store folder).

 

3. Check .htaccess file in your dev site folder.

Open .htaccess in dev site folder, search all occurances of word "Rewrite". Maybe there is the rule that causes the issue. Make a copy of .htaccess file before modifying it, so you can undo any changes, just in case.

 

Let us know how it goes.

-------Store Manager for Magento 1.x and 2.x - enhances the functionality of default admin web interface, speeds up inventory management, automates daily tasks.

Re: Dev site is redirecting, looking for files in FTP

The public_html is the root folder for the dev site correct?  If so the .htaccess fild in the dev folder has this:

 

############################################
## enable rewrites

Options +FollowSymLinks
RewriteEngine on

############################################
## you can put here your magento root folder
## path relative to web root

RewriteBase /

############################################
## Canonical URL
##

#RewriteCond %{REQUEST_METHOD} ^GET
#RewriteCond %{HTTP_HOST} !^saffireecigs\.com$
#RewriteRule ^(.*)$ http://dev.saffireecigs.com/$1 [R=301,L,QSA]

 

Then a TON of rewrite rules for broken links etc. 

Re: Dev site is redirecting, looking for files in FTP

refresh config cache

system->cache management

Re: Dev site is redirecting, looking for files in FTP

tried refreshing cache, still redirects.