Skip to content

Instantly share code, notes, and snippets.

@seigieu
seigieu / pricewars2_customfunctions_split.php
Created June 8, 2020 10:57
PriceWars II Custom function offer splitter
<?php
// Custom Function dla modułui PriceWars II
// https://pl.seigi.eu/modul-prestashop/pricewars2.html
// Skrypt pozwala na automatycznie rozdzielenie oferty na 2 XML
function pricewars2_product(\pricewars2\product $product, $id_xml, $id_lang, $service, $settings, $module){
if($id_xml == 1 && $product->id_presta <= 9000){
throw new \pricewars2\pricewarsSkipException('Produkt ze starej oferty');
}
if($id_xml == 2 && $product->id_presta > 9000){
@seigieu
seigieu / processor.php
Created March 16, 2019 17:36
This processor is intended for use in Daux.io normalizing urls
<?php
/**
* This processor is intended for use in Daux.io
* It may be dangerous in case you're not carefull while naming directories
*
* File Xxx.md and xxX.md would be translated into xxx.md
* File geś.md and gęs.md would become ges.md
*
* You've been warned :)
@seigieu
seigieu / example.php
Created August 3, 2018 15:37
Arena.pl - Deifnicja f
<?php
// Aby pominąć produkt należy zdefiniować w konfigurajci sklepu funkcję:
function seigiarenapl_hook($product){
// A nastepnie, jeśli spełni wymagany warunek, to wyrzucić wyjątek:
if(warunek())
throw new seigi\arenapl\skipException('Produkt nie spełnił wymagania');
}
<?php
/*
For CMSMadeSimple CMS Platform
This file is a fix for https://forum.cmsmadesimple.org/viewtopic.php?f=3&t=71067
Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in lib/html_entity_decode_utf8.php on line 38
*/
//============================================================+