Contact_us

Open to all! Ask other shopowners for help.
ecartz
Core Team
Posts: 3084
Joined: Tue Nov 05, 2019 6:02 pm
Phoenix Version:
Has thanked: 4 times
Been thanked: 208 times

Re: Contact_us

Post by ecartz »

burt wrote: Fri Jun 10, 2022 7:53 am I have been moving all my addons over to an input box rather than a selection of set values, for the reason that @Kofod95 describes - better flexibility of display.

However, a small part of the PI system is slightly different as the logic requires just a number (which is what the selection does).
And this is exactly why I was reluctant to make changes to that kind of functionality without Burt's input -- that there might be a specific reason. But regardless, we don't have to make those kind of decisions now. Because we have Burt's input again.
Omar_one wrote: Mon Jul 25, 2022 5:50 pm will this become as PRO addon ?
As I stated earlier. If we add the modularization to anything, I think that we should add it to core. And enough modules to duplicate the current behavior. Or we should remove contact_us.php from core entirely. I'd prefer to just add to core.

It makes perfect sense to me to put modules with new features only in Pro. Because Pro is a good place to have new features.

I can put the modularized contact_us.php in core in 1.0.8.18 if that's what we want to do. I won't want to put it later in the 1.0.8.* series, because I want to start cutting release candidates for 1.0.9.0 soon. And we should be feature frozen before that.

But in any case, if I grabbed the right two packages from earlier in this thread, here's the 1.0.8.17 version:
CU_modular.zip
You do not have the required permissions to view the files attached to this post.

Tags:


Join The Code Co-op to get access to your library in the Code Co-op Forum
raiwa
Certified Developer
Posts: 1640
Joined: Sat Dec 21, 2019 8:08 am
Phoenix Version: 1.1.0.6
Has thanked: 70 times
Been thanked: 152 times

Re: Contact_us

Post by raiwa »

- admin files are missing in the above package
- $GLOBALS['Linker']->build('contact_us.php') in language file gives error
Changed to:

Code: Select all

  const FORM_CONTACT_US_SUCCESS = '<div class="alert alert-success"><b>Thank you.</b> Your enquiry has been sent to the Shopowner.<br><br>If you need to send us another mail, please <a class="alert-link" href="%s">click here</a>.</div>';
and this in tpl_cu_form.php:

Code: Select all

    printf(FORM_CONTACT_US_SUCCESS,  $GLOBALS['Linker']->build('contact_us.php'));
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
ecartz
Core Team
Posts: 3084
Joined: Tue Nov 05, 2019 6:02 pm
Phoenix Version:
Has thanked: 4 times
Been thanked: 208 times

Re: Contact_us

Post by ecartz »

raiwa wrote: Thu Aug 04, 2022 3:59 pm - admin files are missing in the above package
- $GLOBALS['Linker']->build('contact_us.php') in language file gives error
From 1.0.8.17 on, no extra admin files should be needed. All that's needed in admin to modularize a new page is to manually edit the GROUP_KEYS constant in admin/includes/modules/cfg_modules/cfgm_layout.php -- contact_us is already there. There's probably a way to hook that, but it would happen later. So it would set to the wrong value and then you fix it in a (preAction?) hook afterward. I don't want to get farther into it in this topic, where it isn't necessary. Feel free to ask a new question (either in a fresh topic or in the 1.0.8.17 topic in the Team forum) if you need it for something.

Burt posted the other fix at viewtopic.php?p=9723#p9723

I've added it to the zip to download. Thank you.

Anyone who already downloaded the zip should either follow Burt's directions to fix it manually or download a new copy of the files. It should be fine to just copy the old files over the new. Unless there's something else that I missed, people who are downloading from now on should get the right files.
raiwa
Certified Developer
Posts: 1640
Joined: Sat Dec 21, 2019 8:08 am
Phoenix Version: 1.1.0.6
Has thanked: 70 times
Been thanked: 152 times

Re: Contact_us

Post by raiwa »

Works nice except when installing a contact us module, I get entrances for both, contact us and product info modules entered in the MODULE_CONTENT_PI_INSTALLED configuration entry.
And when installing a product_info module, I get entrances for both type of modules in MODULE_CONTENT_CU_INSTALLED. It produces then fatal error on the pages.
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
raiwa
Certified Developer
Posts: 1640
Joined: Sat Dec 21, 2019 8:08 am
Phoenix Version: 1.1.0.6
Has thanked: 70 times
Been thanked: 152 times

Re: Contact_us

Post by raiwa »

raiwa wrote: Sat Feb 18, 2023 6:55 pm Works nice except when installing a contact us module, I get entrances for both, contact us and product info modules entered in the MODULE_CONTENT_PI_INSTALLED configuration entry.
And when installing a product_info module, I get entrances for both type of modules in MODULE_CONTENT_CU_INSTALLED. It produces then fatal error on the pages.
Found it: I didn't have the correct version: "admin\includes\modules\cfg_modules\cfgm_layout.php
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
Moxamint
Member
Posts: 93
Joined: Fri Nov 06, 2020 10:36 am
Phoenix Version:
Has thanked: 33 times
Been thanked: 3 times

Re: Contact_us

Post by Moxamint »

Could anyone confirm this add-on is compatible with Phoenix v1.8.20? If it does, then I must have done something wrong as I got a blank contact_us page after the installation.

Thanks, Eddy
raiwa
Certified Developer
Posts: 1640
Joined: Sat Dec 21, 2019 8:08 am
Phoenix Version: 1.1.0.6
Has thanked: 70 times
Been thanked: 152 times

Re: Contact_us

Post by raiwa »

raiwa wrote: Sun Mar 12, 2023 4:20 pm Glitch with layout modules:
new 1.0.8.21 installation: only exists: MODULE_CONTENT_PI_INSTALLED in db configuration, MODULE_LAYOUT_INSTALLED doesn't exist.
MODULE_CONTENT_PI_INSTALLED shows:

Code: Select all

pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
When I edit pi gallery module: appears: MODULE_LAYOUT_INSTALLED in db configuration

Code: Select all

pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
When I uninstall pi gallery:
MODULE_CONTENT_PI_INSTALLED shows:

Code: Select all

pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
which is wrong, pi_gallery.php; is uninstalled. But everything works like expected

MODULE_LAYOUT_INSTALLED shows:

Code: Select all

pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
When I install again pi gallery:
MODULE_CONTENT_PI_INSTALLED shows:

Code: Select all

pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php;pi_gallery.php
MODULE_LAYOUT_INSTALLED shows:

Code: Select all

pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
admin\includes\modules\cfg_modules\cfgm_layout.php includes support for the modularized contact_us and index pages. But when I add the modularized contact_us package from this thread:
viewtopic.php?f=28&t=1382
and I install the form contact us layout module, I get the following:
MODULE_LAYOUT_INSTALLED shows:

Code: Select all

cu_form.php;pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php
MODULE_CONTENT_CU_INSTALLED shows:

Code: Select all

pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php;cu_form.php
including all product_info modules, which is wrong and produces the following error on the contact_us page because it tries to load product_info modules:

Code: Select all

Fatal error
: Uncaught Error: Call to a member function get() on null in C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\includes\modules\pi\product_info\pi_gallery.php:35 Stack trace: #0 C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\includes\modules\content\contact_us\cm_cu_modular.php(44): pi_gallery->getOutput() #1 [internal function]: cm_cu_modular->{closure}(Object(pi_gallery), 0) #2 C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\includes\modules\content\contact_us\cm_cu_modular.php(44): array_walk(Array, Object(Closure)) #3 C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\includes\system\versioned\1.0.8.4\template.php(106): cm_cu_modular->execute() #4 C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\templates\override\includes\pages\contact_us.php(28): Template->get_content('contact_us') #5 C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\contact_us.php(54): require('C:\\xampp_8.0_ne...') #6 {main} thrown in
C:\xampp_8.0_new\htdocs\Phoenix_1.0.8.21_beta\includes\modules\pi\product_info\pi_gallery.php
on line
35
The same happens when I install then the layout product info model "Model".
I get the contact us module added to MODULE_CONTENT_PI_INSTALLED:

Code: Select all

cu_form.php;pi_gallery.php;pi_img_disclaimer.php;pi_options_attributes.php;pi_buy_button.php;pi_model.php
and the correspondent error on the product info page.
And following answers by @ecarts
Public Phoenix Change Log Cheat Set on Google Sheets
https://docs.google.com/spreadsheets/d/ ... sp=sharing

Need Help?viewtopic.php?f=10&t=27
lecarlb
Contributor
Posts: 316
Joined: Mon Oct 26, 2020 5:26 pm
Phoenix Version:
Has thanked: 48 times
Been thanked: 9 times

Re: Contact_us

Post by lecarlb »

Moxamint wrote: Wed Mar 22, 2023 7:37 am Could anyone confirm this add-on is compatible with Phoenix v1.8.20? If it does, then I must have done something wrong as I got a blank contact_us page after the installation.

Thanks, Eddy
I'm having the same issue. Did you get it resolved? Thanks
Moxamint
Member
Posts: 93
Joined: Fri Nov 06, 2020 10:36 am
Phoenix Version:
Has thanked: 33 times
Been thanked: 3 times

Re: Contact_us

Post by Moxamint »

lecarlb wrote: Thu Oct 05, 2023 5:09 am
Moxamint wrote: Wed Mar 22, 2023 7:37 am Could anyone confirm this add-on is compatible with Phoenix v1.8.20? If it does, then I must have done something wrong as I got a blank contact_us page after the installation.

Thanks, Eddy
I'm having the same issue. Did you get it resolved? Thanks
No, I gave up using it. According to the developers in the forums, this mod won't work correctly without tweaking the core. Maybe 1.0.8.21 will address that.

Cheers, Eddy
heatherbell
Senior Contributor
Posts: 2540
Joined: Mon Oct 07, 2019 4:39 am
Phoenix Version:
Has thanked: 35 times
Been thanked: 243 times

Re: Contact_us

Post by heatherbell »

Moxamint wrote: Thu Oct 05, 2023 5:31 amMaybe 1.0.8.21 will address that.
Yes it does:
viewtopic.php?f=28&t=2051


Join The Code Co-op to get access to your library in the Code Co-op Forum
Post Reply