WebSite X5Help Center

 
Melissa K.
Melissa K.
User

Cart converted pages into php  en

Автор: Melissa K.
Просмотрено 316, Подписчики 1, Размещенный 0  

Hi there,

Ever since the new update, I've found that the pages with the cart are getting converted into php pages. While it's not a problem by itself, the issue is that my client has used the old url (with the html extension) on social media and forum posts, too many to be manually changed or removed.

Essentially, I'm wondering how I could go about resolving this? While I'm not opposed to the php version, is there a way to leave it as html? Or create an html copy? Does the program offer a redirect link?

Thank you.

Размещено
17 Ответы - 3 Полезно - 1 Корректно
Aleksej H.
Aleksej H.
Moderator
Лучший пользователь месяца RU

Hello.

"I'm wondering how I could go about resolving this?" - create 301 redirect.

"While I'm not opposed to the php version, is there a way to leave it as html?" - no.

"Or create an html copy?" - no.

"Does the program offer a redirect link?" - no.

Читать больше
Размещено От Aleksej H.
Melissa K.
Melissa K.
User
Автор

Hi Aleksej,

My client's domain doesn't allow for htaccess files. Are there any other alternatives?

Читать больше
Размещено От Melissa K.
Melissa K.
Melissa K.
User
Автор

I just wanted to add one more thing. On the website preview in the program, it shows the pages as having html file extensions, even though they export as php...why can't it be fixed?

Читать больше
Размещено От Melissa K.
John S.
John S.
User

Hello Melissa

It is not a matter of a fix.

When you have some html, CSS and Js it can all be processed on your PC locally. If there is something special that requires special code  ( database access or so ) it has to be made in PHP. PHP cannot be processed locally on a computer. It has to be  processed on a server.

So - there is a reason why the pages is made as php.

Читать больше
Размещено От John S.
Melissa K.
Melissa K.
User
Автор

No, I understand the logistics of the different coding languages, what I mean is that the pages were previously html, but now they're getting converted to php only if I edit them. I'm wondering what changed, and why it's happening now?

Читать больше
Размещено От Melissa K.
Paul M.
Paul M.
Moderator
Лучший пользователь месяца EN

Hello Melissa,

If you make use of certain features in the Shopping Cart then WebSite X5 will require the file extension to be changed so that the PHP code for those features can be run on the server.

Show Availability is one such feature:

Show Availability: this displays both an icon for the Approximate quantity and the number indicating the Available quantity in the product card.

If you enable the Show Availability option, and there is at least one product which has this type of availability displayed, then the page that contains the Product Catalog Object must have a .PHP extension: use the File Name Format option in the Page Properties | Expert window to do this.

ref: https://help.websitex5.com/en/v2020.2/pro/index.html?ogg_elenco_tab2.htm

When previewing pages it is not possible to interact with the server, and this is why WebSite X5 will sometimes display warnings that full functionality can only be tested once the project files have been uploaded to the server.  It is also the reason why the preview pages carry an .html file extension.

Kind regards,

Paul

Search the WebSite X5 Help Center

Читать больше
Размещено От Paul M.
Melissa K.
Melissa K.
User
Автор

Hi Paul,

The thing is though, I'm not using the available quantity option. The only things I have are the image, name, description, and price - sometimes it's just the name and the price, as well as the purchase button.

I haven't changed anything from before, and yet I still have some pages using html from before the update, and php for pages I have made changes to, such as adding new products.

Читать больше
Размещено От Melissa K.
Paul M.
Paul M.
Moderator
Лучший пользователь месяца EN

Show Availability is just an example.

The Shopping Cart is becoming ever more sophisticated all the time.  There must be some part of it which you are using that makes use of PHP scripts, else WebSite X5 wouldn't prompt for them or request that the file extension be altered.

We can ask Incomedia to take a look at your project file if you like, to confirm beyond all doubt?

Читать больше
Размещено От Paul M.
Melissa K.
Melissa K.
User
Автор

Yes, I think that would be preferable, as I do need to figure this out.

Читать больше
Размещено От Melissa K.
Aleksej H.
Aleksej H.
Moderator
Лучший пользователь месяца RU

"My client's domain doesn't allow for htaccess files. Are there any other alternatives?" - find out in the technical support of your Hosting how redirects can be configured and do it.

Читать больше
Размещено От Aleksej H.
Paul M.
Paul M.
Moderator
Лучший пользователь месяца EN

Just an update, Melissa...  I asked Incomedia to take a look at this, as per your request.

Please continue to monitor the thread for an official reply, which usually takes anything between 24-72 hours.

Читать больше
Размещено От Paul M.
Incomedia
Elisa B.
Incomedia

Hi Melissa, 

thank you for getting in touch. 

I confirm that in order to function properly all the pages related tho the e-commerce need to be set as PHP. The PHP version which needs to be set on the server if you are using the version 2020.2 of WebSite X5 is at least 7.1.

Thanks! Kind regards.

Читать больше
Размещено От Elisa B.
Melissa K.
Melissa K.
User
Автор

Hi Elisa,

I'm a bit confused though, because the pages were just changed to PHP recently, and I don't know why they changed. All I did was add a new item, but the template remained the same.

Aleksej - thanks for the tip, wound up creating some handcoded html redirecting you now pages.

Читать больше
Размещено От Melissa K.
JJ. JUAG
JJ. JUAG
User

One way we use is a redirect via xxx.html to xxx.php to catch the existing links to html is a .htaccess code line, so we can target individual permanent redirects from html to php.
Example cod line for Transfer with .htaccess entry:

RewriteRule ^xxxxx\ .html$ /xxxxx.php [R = 301, L]

JJ.

Читать больше
Размещено От JJ. JUAG
Incomedia
Stefano G.
Incomedia

Hello Melissa

By any chance, could it be that you used any kind of Object in the Header of Footer too that is forcing the page into PHP?

Double check that too. If you try to convert the page back to HTML, is it locked to PHP in Step 3 -> Page Properties?

if it is, something is definitely using PHP there

Let me know here

Thank you

Stefano

Читать больше
Размещено От Stefano G.
Melissa K.
Melissa K.
User
Автор

Hi Stefano,

If it was something in the header or footer, wouldn't every single page be php? This changed with the latest update. All I did was add one more item (just checking off another item in the product list), and suddenly it's telling me that the page needs to be php. Is there a limit of items that converts it to php?

Читать больше
Размещено От Melissa K.
Melissa K.
Melissa K.
User
Автор

Figured it out - it was the product specific discount.

Читать больше
Размещено От Melissa K.