Redirect when the shop is closed

  • Posts: 55
  • Thank you received: 2
  • Hikaserial Subscription
9 years 2 weeks ago #246977

-- HikaShop version -- : 2.6.4
-- Joomla version -- : 2.5.11
-- PHP version -- : 5.3.29

Hi,

We're migrating our shop to an newer version of Joomla, but also leaving the existing site active. As such we're linking to the new shop from the old Joomla instance, and have "closed" the shop on the old instance.
Is it possible to have Joomla redirect the browser to the NEW shop URL, rather then show the message about the shop being down?

If that's not possible, is there a translation key we need to change to modify the "shop closed for maintenance" message?

Thanks,
Oliver

Please Log in or Create an account to join the conversation.

  • Posts: 84233
  • Thank you received: 13675
  • MODERATOR
9 years 2 weeks ago #246980

Hi,

Usually, you would do a redirect in your htaccess:
www.inmotionhosting.com/support/website/...edirect-via-htaccess
But if you want to change the message displayed by HikaShop when you turn on the shop in maintenance setting of the HikaShop configuration, you can use a translation override:
www.hikashop.com/download/languages.html#modify
on the key:
SHOP_IN_MAINTENANCE="The shop is in maintenance"

Please Log in or Create an account to join the conversation.

  • Posts: 55
  • Thank you received: 2
  • Hikaserial Subscription
9 years 2 weeks ago #247017

Hi Nicolas,

The htaccess is what we'll go for, but can you advise on WHAT the re-write rule should look like for HikaShop (and not affect the rest of Joomla)?

An example of the kind of link I'd like to capture is:
www.oursite.xyz/index.php?option=com_hik...y-product&Itemid=131

Though I'd like to capture anything heading to the shop (for any product) and redirect to the root of shop.oursite.xyz/
(obviously I've renamed the domain)

I can probably get there by trial and error, but if you can suggest the correct form, I'd be very grateful!
Thanks,
Oliver

Please Log in or Create an account to join the conversation.

  • Posts: 84233
  • Thank you received: 13675
  • MODERATOR
9 years 2 weeks ago #247019

Hi,

It depends.
You've given a non SEF URL. Aren't you using SEF on your website ?
Are you using different menu items for your shop ?
Is the menu structure the same on the new website ?
All these questions can influence the way to write your htaccess code. It can be as simple as 2 lines or require a few tens of lines based on what you want to redirect and how.
So I can't provide a simple answer besides giving you the link to the documentation which explains how to write htacess redirect rules.

Please Log in or Create an account to join the conversation.

  • Posts: 55
  • Thank you received: 2
  • Hikaserial Subscription
9 years 2 weeks ago #247062

Do you guys take lessons in how to be unhelpful?

SEF, no.

As I said, I just wanted to capture the HikaShop element of a URL in the old site, and redirect **to the root** of the new website - I'm not trying to replicate menu structures or match products. Funnily enough, my job isn't understanding Joomla menus or htaccess rules, so I kind of hoped you might offer some advice.

I'll work it out myself.

Please Log in or Create an account to join the conversation.

  • Posts: 84233
  • Thank you received: 13675
  • MODERATOR
9 years 2 weeks ago #247071

Hi,

You provided a non SEF URL in your previous message, but in your first message, the URL you provided has a shop with SEFed links. Thus I thought that you made a mistake but didn't know where so hard to say what to do precisely not knowing what you need exactly. It's not about trying to be unhelpful.
But if your shop doesn't have SEF URLs and you want to always redirect to the home of the other website, then you can try like that:

RewriteCond %{QUERY_STRING} option=com_hikashop
RewriteRule http://shop.oursite.xyz/ [R,L]

Please Log in or Create an account to join the conversation.

  • Posts: 55
  • Thank you received: 2
  • Hikaserial Subscription
9 years 2 weeks ago #247104

Hi Nicolas,
Thanks for the response - the old shop didn't use SEF, but the new one does - sorry if that confused things.

Thanks for the example - I'll try it out.
Cheers,
Oliver

Please Log in or Create an account to join the conversation.

Time to create page: 0.066 seconds
Powered by Kunena Forum