Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [base-url]

Denotes question regarding Magento Base URL

0
votes
1answer
28 views

Magento 2 Base Url path issue custom theme

I have a Magento 2.3.1 site installed in a subfolder and I have a problem with base URL. When I have a link like this < a href="#" > LINK < /a > Instead of this www.domainname.com/...
0
votes
1answer
10 views

Using ngrok with Magento 1 issue

I have a virtual host set up. My local url is http://test.local When I start ngrok, my local url will become: http://test.local.ngrok.io so I changed my base secure and unsecure url to: http://test....
0
votes
1answer
36 views

Magento 2 - How to get Base URL in cronjob

In other file I use this code to get base URL $this->storeManager->getStore()->getBaseUrl() where $this->storeManager is a instance of \Magento\Store\Model\StoreManagerInterface My ...
0
votes
0answers
20 views

Same DB for multiple stagings

I am creating multiple staging servers for my Magento 2 website. staging1.mywebsite.com staging2.mywebsite.com staging3.mywebsite.com Is it possible to have single database for all 3 of my staging ...
4
votes
1answer
62 views

Magento2 Getting error as variable @baseUrl is undefined in file /var/view_preprocessed

On doing php bin/magento setup:static-content:deploy -f I am getting error Compilation from source: vendor/magento/theme-frontend-blank/web/css/email-inline.less variable @baseUrl is undefined ...
1
vote
1answer
14 views

Magento 2.1.3 Build multiple store views with unique subdomains pull CSS and JS from parent website URL?

I've been googling this all afternoon, suffering from Search Engine blindness, so much so I even tried bing for a moment... I have a multiple language site set up with different URL's assigned to ...
0
votes
1answer
26 views

Magento 2 : Update url to domain

I'm using an Instance of Ubuntu 16.04 lts on Google to run a store, but I'd like to point to my domain. Wich line on Apache2 should I update?
1
vote
0answers
39 views

M2: getBaseUrl() - StoreManagerInterface vs StoreConfigInterface

If someone asks for getting base URL, the answer is always to use StoreManagerInterface, like ... protected $storeManager; public function __construct( ... \Magento\Store\Model\...
0
votes
1answer
18 views

Magento Multisite links go to wrong domain

I have created a new website within my Magento (1.9.3.10) I've created a home page and got the menu visible. When you click on a Menu item, it links to my other website domain, showing a 404. I have ...
1
vote
2answers
128 views

Magento2: Remove home after base url

How to remove /home after baseUrl ? www.baseurl.com/home I want to redirect www.baseurl.com/home to www.baseurl.com (301)
0
votes
1answer
53 views

Magento 2.2.6 CSS JS not loading in admin panel after changing base and custom admin URLs

It's a multi store site in development and I changed the test URL to one of the production URLs for the default Base URLs and one of the store Base URLs. I also changed the option to Use Custom Admin ...
0
votes
0answers
351 views

TCPDF ERROR: Unable to create output file in Magento2

I am trying to get PDF Download able, I installed TCPDF library by this: composer require tecnickcom/tcpdf and created PDF Document as: // create new PDF document $pdf = new \TCPDF(...
0
votes
1answer
32 views

Full base url appended after base url when reaching page

For a demo environment, I had to upload my Magento project to a server, without a domain name. My Magento base URL is http://62.221.209.128/plesk-site-preview/rodrigootazu.com/62.221.209.128/, but as ...
1
vote
1answer
25 views

How to change base_url of other stores?

I exported a live database from a magento installation with 2 websites and 3 different stores and imported it on another magento installation. I already changed the base_url of the main store, but ...
0
votes
2answers
51 views

Magento 1.9.3.8 Full https causes double / ending

I made my entire site https by changing the unsecure_url to https rather than http. Then in my .htaccess I added: RewriteCond %{HTTPS} off RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI}/ [L,R=...
0
votes
2answers
212 views

Two Magento apps with single Database and Base url

I just need a help from you people. I am trying to connect two Magento web applications with a single database. It was done successfully but the problem I am facing is with the base URL. I have two ...
0
votes
0answers
26 views

Magento 2: fix IP for wmwear Magento

I am using Bitnami Magento WMWare for development. Its usually generate IP address (192.168.0.104). I close the machine and when I start this machine, its generate new IP (192.168.0.107). and I cant ...
-1
votes
1answer
168 views

Change base url of Magento 2 without Changing in Magento Database

How to Change base URL of Magento 2 without Changing in Magento Database For Example: magnentoxyz.com means it will redirect to my Magento frontend localhost/ means it will go to phpmyadmin page
1
vote
1answer
1k views

Get base url in email template

I've created a custom footer template inside my theme folder app/design/Vendor/Module/Magento_Email/email/footer.html , the problem is i need to get base url inside this html file.
0
votes
2answers
156 views

CSS/JS don't load after changing URL

I have two store views, I changed one of them from wesbitetest.com to websitetest.com/fr-ca/ but the front end didn't load the js and CSS files as expected, and the URL becomes websitetest.com/fr-ca/?...
0
votes
1answer
130 views

Server folder appears as output url for media, js and skin

Any ideas why Magento 1.9.2.4 sets the beginning of the media, skin and js url's like this /var/www/domain.com/html/ instead of normal http://www.domain.com like it has been set in unsecure_base_url ...
2
votes
0answers
1k views

Get base url in css file

Is there a way to load base url for background-image in css file? for example: background-image: url('{base_url}/myimage.jpg'); background-repeat: repeat;
0
votes
4answers
643 views

How to get secure baseurl (https) in magento 2? [duplicate]

with this code im getting http://url.com i want to get https://url.com using object manager. i'm using magento 2.0.4 echo $store->getBaseUrl(\Magento\Framework\UrlInterface::URL_TYPE_WEB); echo '&...
1
vote
1answer
2k views

Magento 2: Get base URL in web template [duplicate]

How can we get Magento 2 base URL in web template (.html file) ? Note: I am talking about web template (.html file). Not about general templates file (.phtml file).
0
votes
1answer
620 views

Changing base_urls to work on localhost

I have some databases which we use for our staging servers to test changes to code, and I want to import them and use them locally. I've managed to import the database fine, but my admin panel is ...
1
vote
1answer
88 views

How does Magento determine the route / getting 404 behind proxy

I have the following constellation: NGINX in front of two apache vhosts One Vhost running Magento (port 8181) Proxy pass of https://example.de.testing.abc.de/en/shop/ -> http://127.0.0.1:8181 No ...
3
votes
0answers
43 views

Can multiple Magento installations be connected to one database?

I need to run multiple different Magento servers off of one central database. Unfortunately, the Base URL causes the site to redirect preventing access to the admin panels of all but one server. Is ...
1
vote
0answers
41 views

Magento 1 - Is it safety to use Store Code in URLs?

I need a multi language store using domain.com/fr/ domain.com/it etc structure (are more than 10 stores so domain.en domain.fr domain.it etc is not possible) i can apply it in Configuration > Web > ...
1
vote
1answer
109 views

Magento 2: base URL to use in hardcoded links

I am working on a Magento 2.1.7 shop and I have created a child-theme of Magento Blank. In the back-end, I have created a block with a custom, hardcoded, navigation like: <nav> <ul> &...
1
vote
2answers
478 views

Page display error after changing base url

I am setting up a new Magento 2 store on AWS. After installed M2 on my server (13.210.72.64), the site'base url was 13.210.72.64/magento2 and then I changed it to 13.210.72.64 in the admin panel(...
1
vote
1answer
3k views

SecurityError: Permission denied to access property “tinymce” on cross-origin object

I'm using Magento 1.9.3.4 AND KeyCDN. I configured the js/media/css files to come from CDN. On the CDN I enabled the CORS. The CDN uses HTTP/2, shared SSL and the Origin Shield setting is set to "...
1
vote
1answer
1k views

Magento 2 - The words “admin” and “index” appear twice in the admin URL

I have Magento 2.1.9 installed. After a futile attempt to change the admin URL, it resulted to me not gaining access to the admin panel. After resolving that issue, the admin URL displays like this: ...
0
votes
1answer
341 views

Update Unsecure, Secure, and Cookie URLs in phpMyAdmin from Production to Staging

I'm looking for a way to quickly update all unsecure, secure, and cookie domain URLs through phpMyAdmin. My situation is to change unsecure & secure URLs (I use always-on HTTPS) from ...
3
votes
1answer
114 views

How to add a virtual url in Magento 2

I have the following situation: I have a multiple store views and for one of the store I have let's say this url: wwww.myurl.com. What I try to do, is to change the base url to : www.myurl.com/...
1
vote
1answer
640 views

Programmatically change base url of store

i setup websites / store / storeview in code from controller with this : public function createWebsite($nom, $language){ $code = $this->transformerEnURL($nom); $category = $this-&...
1
vote
1answer
2k views

How to change product URL and redirect?

Here's the situation I need to redirect one of my product to homepage make it as homepage at the same time the URL must be changed to home, so instead of www.example.com/sample-product it should be ...
5
votes
3answers
8k views

Get base url from js file

i want to retrieve a base url and append it with my module controller link from .js file, so it's impossible to use block to get the base url. so far i've done this: define([ 'jquery', 'mage/...
0
votes
1answer
710 views

Add Store Codes to URL

In admin panel under Url options, I want to turn on Store codes on Url, since I want to visit my country-specific pages. I'm running locally (using WAMP) so my IP is 127.0.0.1:8888. I did set my host ...
3
votes
2answers
1k views

Mutiple website with multiple sub domain in Magento 2

I'm trying to implement multiple website in Magento 2.1.3 For that, I have created an extra website store and store view My site URL is like www.example.com My subdomain is www.kw.example.com(where ...
0
votes
3answers
2k views

How to get admin side base url in magento 2?

$objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $storeManager = $objectManager->get('\Magento\Store\Model\StoreManagerInterface'); echo $storeManager->getStore()->...
0
votes
1answer
405 views

How To Test SSL On Development Server Without SSL Certificate [duplicate]

I'm testing some code that changes a link to use the secure base URL, but my development server does not have an SSL certificate. I'm trying to fake it and have so far been unsuccessful. I have links ...
0
votes
1answer
44 views

Magento2: Duplicated stores - base_url problem

We have store Store A installed in public_html/magento2 (available under live.storeAAA.com) We duplicated public_html/magento2 -> public_html/magento_copy So we ended up with 2 folders with exactly ...
0
votes
2answers
1k views

Magento 2 After updating the admin URL getting 404 Not found page

I have changed the admin URL using the below command line: php bin/magento setup:config:set --backend-frontname="admin_path" I have followed the below answer for change the admin URL: How to change ...
0
votes
0answers
52 views

Multisite getUrl not working on server

I have setup two site on localhost server. It's working fine on local. But on server it gives wrong url. It give base url on ajax call. When I use getBaseUrl it give right url Site setup. Website1 :...
0
votes
1answer
389 views

Get Home page url in outside magento php file

I want to get magento home page url in outside magento file I have added below code in my custom file pdf.php require_once("app/Mage.php"); Mage::app(); $connectionWrite = Mage::getSingleton('core/...
2
votes
2answers
3k views

Magento2 - Use placeholder {{base_url}} in multistore

In magento1 you can set the base url's in a multistore like this: {{base_url}}en/, {{base_url}}nl/, etc. Trying that in Magento 2 will result in the following Error: Invalid Base URL. Value must ...
0
votes
2answers
3k views

Multi website and multi store view with custom url in magento 2

I have a magento 2 installed and configured the following: 1) default website with 1 store view called us_en 2) eu website with 1 store view called eu_en When I change base url to store view like ...
1
vote
0answers
45 views

How to get base url in js without using block and phtml in Magento 2 [duplicate]

I have a custom js which will be loaded every time in backend, i want to get the site base url without using phtml pure in js, for now i'm stuck in this: define(['mage/url'], function (url) { ...
0
votes
1answer
102 views

Magento 1 HTTPS rel -canonical tag and redirect

When we change the base unsecure URL to https does this also update the rel -canonical tag on pages. My concern is how are these changed to HTTPS as these will also need to be changed to HTTPS for the ...
1
vote
2answers
802 views

Admin URL and DB config for development area

I recently created a Development/Staging copy of my site/database and everything seems to be working correctly on the front end. So when I visit dev.mysite.com I am able to browse my store and it ...