JBJBJB
11-26-2005, 03:31 PM
Hello,
I experience some strange problems while developing an advanced plugin for integrating an existing shop into a subdreamer site. I hope someone can point me in the direction of a solution.
Working of the plugin
I created a new plugin that contains a complete installation of a shop in its subdirectory. That shop is an existing product and I am trying to encapsulate it into a plugin. All pages of the shop will be shown within the site and so far I only had to make two (very minor) changes to both products. So far so good.
How does it work:
I created two new plugins: ShopEngine and ShopContent. The former is invisible and does some initialization. The latter renders the content of the shop and requires the ShopEngine to be loaded on the page BEFORE it is loaded.
I created a Subdreamer category containing only the ShopEngine and the ShopContent plugin, just for testing. It does not contain any other plugins.
Whenever a visitor clicks on a link to the shop, the url is rewritten by some additional .htaccess rules. They rewrite all urls to point to the normal subdreamer page and additional arguments are added to the url. The subdreamer category contains my ShopContent plugin that performs the actual request to the shop (passing the arguments it got from the url) and uses screen scraping techniques. The output of the shop is parsed and the relevant parts will be rendered as the content of the plugin.
The following is happening:
This all works like a charm for 90% of the pages but for the remaining 10%, the ShopEngine plugin renders properly and completely. However, the ShopContent plugin does not even start to load. I can see that from the source since each plugin starts and ends a comment.
When I put another plugin (the ContactForm) between the ShopEngine and the ShopContent plugin, that plugin is not rendered either, so it looks like rendering stops once the ShopEngine is loaded, and only for certain urls. In either case, the remaining part of the site is still properly rendered (the righthand side plugins and the page footer).
Some common thing about all pages is that the url contains a product ID like: products_id=10 when I remove that part manually and then try again, the shop fails to render, but the ContactForm is rendered properly.
Can anyone please tell me what might be causing this strange behaviour? Is there some stop-condition in loading the plugins? Is the products_id value in the url some special exception?
Thanks in advance for any support,
Jeroen
I experience some strange problems while developing an advanced plugin for integrating an existing shop into a subdreamer site. I hope someone can point me in the direction of a solution.
Working of the plugin
I created a new plugin that contains a complete installation of a shop in its subdirectory. That shop is an existing product and I am trying to encapsulate it into a plugin. All pages of the shop will be shown within the site and so far I only had to make two (very minor) changes to both products. So far so good.
How does it work:
I created two new plugins: ShopEngine and ShopContent. The former is invisible and does some initialization. The latter renders the content of the shop and requires the ShopEngine to be loaded on the page BEFORE it is loaded.
I created a Subdreamer category containing only the ShopEngine and the ShopContent plugin, just for testing. It does not contain any other plugins.
Whenever a visitor clicks on a link to the shop, the url is rewritten by some additional .htaccess rules. They rewrite all urls to point to the normal subdreamer page and additional arguments are added to the url. The subdreamer category contains my ShopContent plugin that performs the actual request to the shop (passing the arguments it got from the url) and uses screen scraping techniques. The output of the shop is parsed and the relevant parts will be rendered as the content of the plugin.
The following is happening:
This all works like a charm for 90% of the pages but for the remaining 10%, the ShopEngine plugin renders properly and completely. However, the ShopContent plugin does not even start to load. I can see that from the source since each plugin starts and ends a comment.
When I put another plugin (the ContactForm) between the ShopEngine and the ShopContent plugin, that plugin is not rendered either, so it looks like rendering stops once the ShopEngine is loaded, and only for certain urls. In either case, the remaining part of the site is still properly rendered (the righthand side plugins and the page footer).
Some common thing about all pages is that the url contains a product ID like: products_id=10 when I remove that part manually and then try again, the shop fails to render, but the ContactForm is rendered properly.
Can anyone please tell me what might be causing this strange behaviour? Is there some stop-condition in loading the plugins? Is the products_id value in the url some special exception?
Thanks in advance for any support,
Jeroen