Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Wiki Update


Ivan Holbi

Recommended Posts

@Ivan HolbiThanks for adding this. It cleared up some things I have been struggling with. In the extensions section what does the following mean? I assumed it meant to manually change the url but that didn't work. I also tried looking in the customer edit page after clearing cache - still nothing.

Quote

Now in order to see the returned text let us use the direct query from the controller backend:

extensions?module=CustomersRank&action=renderCustomerField

In the clearing cache text it says the following. Where is the Blog section?

Quote

In the lower blog part we will see out text:

For creating the hooks file, for your example, does it go in the extensions/CustomersRank/ directory? And is it named CustomersRank.php?  I couldn't find a hooks directory in the extensions directory. Where are they normally stored?

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

16 hours ago, Jack_mcs said:

@Ivan HolbiThanks for adding this. It cleared up some things I have been struggling with. In the extensions section what does the following mean? I assumed it meant to manually change the url but that didn't work. I also tried looking in the customer edit page after clearing cache - still nothing.

In the clearing cache text it says the following. Where is the Blog section?

For creating the hooks file, for your example, does it go in the extensions/CustomersRank/ directory? And is it named CustomersRank.php?  I couldn't find a hooks directory in the extensions directory. Where are they normally stored?

Hi Jack,

You are welcome and thank you for your comments.

Regarding "In the extensions section what does the following mean?" we have explained it in more detail in the article now. Please see this explanation below.

"Now in order to see the returned text let us use the direct query from the controller backend via the browser url:

extensions?module=CustomersRank&action=renderCustomerField

It means that if your shop url is http://localhost/oscommerce/, then your backend url is http://localhost/oscommerce/admin/ and the direct query from the controller backend via the browser url is http://localhost/oscommerce/admin/extensions?module=CustomersRank&action=renderCustomerField"

Regarding "In the clearing cache text it says the following. Where is the Blog section?" there was the mistype there, it should be "In the lower block part we will see our text:". Sorry for the inconvenience.

Regarding "For creating the hooks file, for your example, does it go in the extensions/CustomersRank/ directory? and so on" please see the archive to each lesson, in the first lesson archive there is the folder hooks already.

Best regards,

Ivan

  

Link to comment
Share on other sites

2 hours ago, Ivan Holbi said:

url is http://localhost/oscommerce/admin/extensions?module=CustomersRank&action=renderCustomerField"

As mentioned, I had already tried that. When I tried it before my original post it didn't work but didn't cause a failure. But you updated the installed version today and now when I try it is fails with the following. I tried clearing cache but it didn't help.

yii\base\ErrorException: Module 'imagick' already loaded in Unknown:0

 

2 hours ago, Ivan Holbi said:

please see the archive to each lesson, in the first lesson archive there is the folder hooks already.

I don't know where the archive is located. I can't see where that is mentioned in the docs? Maybe I'm just overlooking it.

I ran the generator and tried using the files it generated, which are quite different than the docs describe. It didn't work either. There is a hooks directory but the included file is named .php. Is that correct?

Support Links:

For Hire: Contact me for anything you need help with for your shop: upgrading, hosting, repairs, code written, etc.

All of My Addons

Get the latest versions of my addons

Recommended SEO Addons

Link to comment
Share on other sites

  • 1 month later...
On 9/20/2022 at 4:40 PM, Jack_mcs said:

As mentioned, I had already tried that. When I tried it before my original post it didn't work but didn't cause a failure. But you updated the installed version today and now when I try it is fails with the following. I tried clearing cache but it didn't help.


yii\base\ErrorException: Module 'imagick' already loaded in Unknown:0

 

I don't know where the archive is located. I can't see where that is mentioned in the docs? Maybe I'm just overlooking it.

I ran the generator and tried using the files it generated, which are quite different than the docs describe. It didn't work either. There is a hooks directory but the included file is named .php. Is that correct?

Hi Jack,

Sorry for the delay in reply.

Regarding the upper point please show us your code for us to be able to check it further. It should look something like the following:

$imagine = new \Imagine\Gd\Imagine();

Regarding the lower point you can find the links to the archives after each section in the article - https://wiki.oscommerce.com/index.php?title=Creating_Extension_from_Scratch. Please see the screenshots attached.

Best regards,

Ivan

Screenshot_2.png

Screenshot_5.png

Screenshot_3.png

Screenshot_4.png

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...