How did you find us?

Only uses first word from description in language file - How did you find us?

Only uses first word from description in language file

by plamastus » Mon Apr 26, 2021 5:29 pm

Hi,

Phoenix 1.0.8.0 and 1.0.8.1

There is a problem when adding more than one word descrition to the language file. It only takes into account the first word. See below how it comes out in the error_file:

const MODULE_CUSTOMER_DATA_HOW_FOUND_US_OPTION_WORD_OF_MOUTH = 'Word of Mouth';
couldn't find constant MODULE_CUSTOMER_DATA_HOW_FOUND_US_OPTION_WORD OF MOUTH in
Thanks,
patrick
plamastus
VIP Member
VIP Member
Posts: 83
Joined: Fri Mar 12, 2021 2:09 am
Contact:

Re: Only uses first word from description in language file

by zipurman » Mon Apr 26, 2021 6:55 pm

Fixed. New version 1.2.0 added.
zipurman
aka Preston Lord
-----------
Happy to help where I can ;)

https://phoenixaddons.com
https://www.youtube.com/zipurman/ ** PHOENIX HOW-TO VIDEOS **
Image
User avatar
zipurman
PhoenixCart Developer
PhoenixCart Developer
Posts: 470
Joined: Tue Oct 13, 2020 5:20 pm
Contact:

Re: Only uses first word from description in language file

by lambro28 » Wed Jul 28, 2021 5:29 pm

I have the how find us set to account create / edit / customers.
These are my options as set by me
Facebook, Search Engine, Recommended, Scootering, Jetset, Scooternova, Other

When I am in my account edit, no matter what option I choose, when I re-load that page the drop dox defaults to facebook. Is this correct?
Attachments
zuper.png
lambro28
Posts: 50
Joined: Sun Jan 03, 2021 2:47 pm
Contact:

Re: Only uses first word from description in language file

by ce7 » Tue May 31, 2022 2:24 am

@zipurman
Hi,
Thank you very much for the addon.
For my installation this addon, there is a problem to show up the update information and the inforbox. I did not change any code for the hooks, it just showup Unknow all the time, how can I make the infobox area show up correctly?
Attachments
HowFoundUs_1_3_0-01.gif
ce7
Posts: 26
Joined: Tue Apr 06, 2021 12:26 am
Contact:

Re: Only uses first word from description in language file

by zipurman » Tue May 31, 2022 4:22 am

Change the howFoundUs.php method as follows:

Code: Select all

     function listen_infoBox($attributes){

            GLOBAL $table_definition;
            $found_us = !empty($table_definition['info']->howfindus) ? $table_definition['info']->howfindus : 'Unknown';
            array_push( $attributes['contents'], ['text' => 'Found Us Via: ' . $found_us], );

        }
I will post some new versions of some of these addons soon that catch this stuff with Phoenix Version Checking ;)

Thanks for the video ... much appreciated! Makes it easier to see the issue.
zipurman
aka Preston Lord
-----------
Happy to help where I can ;)

https://phoenixaddons.com
https://www.youtube.com/zipurman/ ** PHOENIX HOW-TO VIDEOS **
Image
User avatar
zipurman
PhoenixCart Developer
PhoenixCart Developer
Posts: 470
Joined: Tue Oct 13, 2020 5:20 pm
Contact:

Re: Only uses first word from description in language file

by ce7 » Thu Jun 02, 2022 12:25 am

zipurman wrote:
I will post some new versions of some of these addons soon that catch this stuff with Phoenix Version Checking ;)

Thanks for the video ... much appreciated! Makes it easier to see the issue.
Thank you zipurman,
it works great now!
Attachments
mg-22-026-02-working ok now.PNG
ce7
Posts: 26
Joined: Tue Apr 06, 2021 12:26 am
Contact: