Move shop to a other and new domain - magento

i’m stuck.
I want to move a magento shop to a new domein.
Example: From testdomain.com/shop to newdomain.com/shop
I worked like this so the old shop on newdomain.com was able to keep running while building a new store on a testplace.
How can i move the shop to the newdomain.com ??
I made a sql backup from the testshop; this is a file of 15MB.
In the file there are references to testdomain.com. Offcource; i need to replace them by newdomain.com.
This replacing takes along time and mostly end ups in crashing file.
Is there another way to move a shop to a new domain ??
Thanks,
Dave
http://p1.b7d.com/magento/meghzal/

dont play with your sql file just import it as it is. if you only have 1 store view you only have to change 2 values to make you shop running.
Copy all file to you new webserver
Make the media and the var folder writeable by the webserver
Edit 'app/etc/local.xml' normally you only have to edit the database connection
With you favorite mysql tool edit the values under these paths: web/unsecure/base_url and web/secure/base_url set them to your new domain like http://newdomain.com/. if you have an ssl certificate use https for the secured one if not use normal http.
Now very important clear the cache. normally the cache is under var/cache but in case this one is not writable magento switches to the tmp folder of you server. So check you tmp folder for something like /tmp/magento and remove it

If you need to COPY installation of Magento to another server use the manual by Fantus here. Beware of different php.ini configuration, and OS (from Win to Unix set correct the rights by chmod)
If you have the same installation and ONLY CHANGING ENTRANCE DOMAIN to the same installation of Magento:
configure your domain A record to IP adress of your server
configure a vitual host of your ewb server (apache or etc) to reverse domain to magento folder
change configuration of new domain in magento/app/local.xml
Clear the magento/var/ folder (not neesesary)

Related

Laravel 5.6 custom storage link/mount to other location on Windows OS

Laravel 5.6 custom storage link/mount to other location on Windows OS
https://laravel.com/docs/5.6/filesystem#configuration
php artisan storage:link will point the
http://localhost/storage to c:/project/storage/app/public
means visit http://localhost/storage/image.jpg = c:/project/storage/app/public/image.jpg
but how to custom the uri link to other location ? eg..
http://localhost/ramdisk/image.jpg link to z:/ramdisk/image.jpg
or
http://localhost/avatar/image.jpg link to z:/avatar/image.jpg
First of all: why would you like to do that? The images you upload should be in /storage/app/... or in /public/images/... Other disks may be unavailable if putting the app on a server.
To clarify, the php artisan storage:link only creates a symlink in /public/ folder pointing to the app/public. (I think in 5.6 it has absolute path so on server or after moving the application you have to delete and generate it again.)
So if you really want to access disk z on your PC from the app you should create a symlink in /public/ folder with the desired name. For example:
http://localhost/ramdisk/... would be a symlink named ramdisk in the public folder and would point to z:/ramdisk/. Then you would be able to access the folder contents as you wish.
Of course you can have multiple symlinks so you would create another one for the avatar folder too. Also make sure that disk z has a public access.
I was not able to test it, but I am sure that it would work, however I would not recommend it. If you want to use something in your app it should be within the app. (Except S3 drivers like amazon cloud storage.) I hope it helped.

Why does my Joomla site subdomain copy the main site?

I'm not a pro with server management, I mainly do web design on Joomla.
Our IT Manager recently left and I was given access to everything since no-one else in our company knows web.
We have a main site. In this example I'll name the site as cookies.com for example sake.
www.cookies.com is the main site. The domain is cookies.com only. We have 3 server accounts for this.
123reg - to buy the domain and renew
heartinterner - to host the website
1and1 - this is where it is redirected (or something), well all the files are found in virtual servers here.
When I go to the virtual servers, there are a couple of directories, and eventually I can find a folder called "var" which leads me to another directory. I go to "www" and I find so many site folders there, including cookies.com and dev.cookies.com and more
My objective was to backup and restore cookies.com to dev.cookies.com so that I can work on it and replace the original cookies.com later on. I use Akeeba Backup for this.
The issue is, as soon as I started making changes to dev.cookies.com, cookies.com also made those changes.
I'm very confused- what's going on here? Is there something written in the files that direct the database or whatever to the same place, for which reason the changes occur together?
Sorry this is very confusing. Please suggest if you can what I can do. I know this might not be much information.
Thank you!
You probably have used the same database for both. Create another database and user for dev.cookies.com and use that database and user to create the new dev site. Check in the configuration.php file that these values should be different.
public $db = 'joomla';
public $password = 'db_password';
public $user = 'root';
These are all database values. Also check these settings
public $log_path = 'C:/xampp/htdocs/joomla/administrator/logs';
public $tmp_path = 'C:/xampp/htdocs/joomla/tmp';

How to name api routing on a webhost sub folder

I have always thought the api controllers where not found by physical paths. The reason I ask is I have a website example.com I created a folder example.com/testing and uploaded my project to there. When I ran it I got errors saying that none of the apiControllers could be found. So I changed /api/apiCustomers to /testing/api/apiCustomers. It then worked, well not the actual posting of any new records. It did locate and retrieve all the records from the database though. But it doesn't seem like that is what I would actually need to do? I have a domain with WinHost and the default publish folder is example.com/myApp
AM I looking at this the wrong way?
To handle request where you do not know the root path, you can use (as in ASP.NET) the ~-character like this:
~/api/apiCustomers
~ will then be replaced by the root (i.e. /api/apiCustomers for prod and /testing/api/apiCustomers for your test environment)

With GroceryCrud, how can I put uploads above application root?

I'm using GroceryCRUD to act as a front end for a database containing news releases. Secretaries can go in and add/edit/delete news releases in the database easily now. Only qualified users are able to access the application root via an .htaccess password. The problem with this is that GroceryCRUD uploads assets such as photos are uploaded to the directory /www/approot/assets/uploads/ which is password protected since /approot/ is protected.
My ideal solution would be to set an upload directory outside of the application root which is where I'm running into trouble. By default this is how GroceryCRUD handles uploads:
$this->grocery_crud->set_field_upload('photo1','assets/uploads/');
I've tried changing it to something like this:
$this->grocery_crud->set_field_upload('photo1','/public/assets/uploads/');
I was hoping this / would make the path start from the document root instead of the application root, but it throws this error:
PHP Fatal error: Uncaught exception 'Exception' with message 'It
seems that the folder "/Users/myusername/www/approot//public/assets/uploads/"
for the field name "photo1" doesn't exists.
This seems to suggest that CI or GroceryCRUD just takes the second argument in set_upload field and just concatenates it onto the end of the site URL that is defined. Is there any way around this that doesn't involve creating a user login system?
Try using relative path.
$this->grocery_crud->set_field_upload('photo1','../assets/uploads/');
.. -> Go up one directory
I ended up implementing a login system outlined in this tutorial:
http://net.tutsplus.com/tutorials/php/easy-authentication-with-codeigniter/
It was quite simple to set up and suits my needs. I found ways to give access to the directory using httpd.conf directives but I feel like this was a more viable solution since I don't have direct access to server configuration files.
Maybe in the future GroceryCRUD will allow placement of uploads outside the application folder.

Domain Name Windows Vista Does Not Exist In The Database

I am trying to install DOTNETNUKE model on my local machine ( Windows Vista) but seem to be running into a problem right after installing the Database. Not exactly sure where to go to fix the problem or what I need to do next. Anyone have any idea how I can deal with this? Thanks in advance.
DotNetNuke Error
--------------------------------------------------------------------------------
Domain Name Windows Vista Does Not Exist In The Database
DotNetNuke supports multiple portals from a single database/codebase. It
accomplishes this by converting the URL of the client browser Request to
a valid PortalID in the Portals database table. The following steps
describe the process:
Web Server Processing
When a web server receives a Request from a client browser, it compares the
file name extension on the target URL resource to its Application Extension
Mappings defined in IIS.
Based on the corresponding match, IIS then sends the Request to the defined
Executable Path ( aspnet_asapi.dll in the case of ASP.NET Requests ). The
aspnet_isapi.dll engine processes the Request in an ordered series of events
beginning with Application_BeginRequest.
HttpModule.URLRewrite OnBeginRequest ( UrlRewriteModule.vb )
The Request URL is parsed based on the "/" character
A Domain Name is constructed using each of the relevant parsed URL segments.
Examples:
URL: http://www.domain.com/default.aspx = Domain Name: www.domain.com
URL: http://209.75.24.131/default.aspx = Domain Name: 209.75.24.131
URL: http://localhost/DotNetNuke/default.aspx = Domain Name: localhost/DotNetNuke
URL: http://www.domain.com/virtualdirectory/default.aspx = Domain Name: www.domain.com/virtualdirectory
URL: http://www.domain.com/directory/default.aspx = Domain Name: www.domain.com/directory
Using the Domain Name, the application queries the database ( Portals table -
PortalAlias field ) to locate a matching record.
Note: If there are multiple URLs which correspond to the same portal then the
PortalAlias field must contain each valid Domain Name in a comma seperated list.
Example:
URL: http://localhost/DotNetNuke/default.aspx
URL: http://MACHINENAME/DotNetNuke/default.aspx
URL: http://209.32.134.65/DotNetNuke/default.aspx
PortalAlias: localhost/DotNetNuke,MACHINENAME/DotNetNuke,209.32.134.65/DotNetNuke
Note: If you are installing the application to a remote server you must
modify the PortalAlias field value for the default record in the Portals
table according to the rules defined above.
Its hard to tell the status of your installation. I'll assume that the database was created and populated during install.
Firstly, look at the table
dbo.PortalAlias
If your planning to run/debug on your local IIS, then you should have an entry for HTTPAlias of
localhost/YOURVIRTUALDIR
When you installed, it is possible that the last step, the default installation of the Portal did not execute. In a similar case, when I selected "Custom" installation, I found that this last step was missing, but didn't yield an error.
Resolution: reinstall (remove everything or install to a new location, use another DB or remove this one prior to reinstalling) and select "Auto" installation for the online wizard. This works and includes the creation of the default portal. Anything automatically configured can be altered later anyway.
I know this might be very late, but for anyone having this issue,
I had the same issue, after I made sure that I have updated the "Portal Alias" table in db, to have a HTTP Alias (for my local host, I set it to localhost:8089 which was equal to what I had set up in IIS binding for DNN website), with the portal ID of 0 (as my portal id was 0),
I was checking to be sure I have updated web.config file with data base connection strings, but then I realized there were two points for database connection in web.config, and I was missing one of them.
So make sure to update both two connections as:
1) <connectionStrings>
2) <appSettings>
Hope this helps.

Resources