We can make this file beautiful and searchable if this error is corrected: No commas found in this CSV file in line 0.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JUD;DENJ;FSJ;MNEMONIC;ZONA | |
1;ALBA;1;AB;7 | |
2;ARAD;2;AR;5 | |
3;ARGES;3;AG;3 | |
4;BACAU;4;BC;1 | |
5;BIHOR;5;BH;6 | |
6;BISTRITA-NASAUD;6;BN;6 | |
7;BOTOSANI;7;BT;1 | |
8;BRASOV;8;BV;7 | |
9;BRAILA;9;BR;2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* @author Daniel Placinta | |
* http://artgames.ro | |
* Heavy inspiration from https://github.com/alceanicu/cnp/ | |
*/ | |
namespace App\Rules; | |
use Illuminate\Contracts\Validation\Rule; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var validateCui = function(cui){ | |
var cif = cui; | |
// Daca este string, elimina atributul fiscal si spatiile | |
if(isNaN(parseFloat(cui)) || !isFinite(cui)){ | |
cif = cif.toUpperCase(); | |
if(cif.indexOf('RO') === 0){ | |
cif = cif.replace('RO', ''); | |
} else { | |
return false; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* ART GAMES BNR Rate Class | |
* | |
* @description A currency rate method for Laravel using BNR's api. The main currency is Romanian LEU (RON). Price response from BNR is compared with the RON currency. The method uses Laravel's caching properties. | |
* @usage \App\Models\Bnr::curs("EUR") | |
* @author Daniel Placinta <[email protected]> | |
* @license MIT | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$fileName = 'export-casete-plastica-' . Mage::getModel('core/date')->date('Y-m-d-h-i-s') . '.xls'; | |
$content = mb_convert_encoding($content, 'UTF-16LE', 'UTF-8'); | |
$this->_prepareDownloadResponse($fileName, chr(255) . chr(254) . $content); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Magento Sweden SSN Validator | |
* @param none | |
* @return boolean | |
* @author Daniel Placinta ([email protected]) | |
* Based on: jquery-validate-personnummer by Sebastian Wallin | |
* Github: https://github.com/wallin/jquery-validate-personnummer | |
*/ | |
if(Validation) { | |
Validation.addAllThese([ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function ro_slugs($cuvant) { | |
$slug = trim(strtolower(stripslashes($cuvant))); | |
$map = array( | |
'/à|á|å|â|ă|â|Â|Ă|ă/i' => 'a', | |
'/è|é|ê|ẽ|ë/i' => 'e', | |
'/ì|í|î|î|Î|Î/i' => 'i', | |
'/ò|ó|ô|ø/i' => 'o', | |
'/ù|ú|ů|û/i' => 'u', | |
'/ș|ș|ş|Ș|Ș|Ş/i'=>'s', | |
'/ț|ţ|ț|Ț|Ţ/i'=>'t', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function addMassAction($observer) { | |
$block = $observer->getEvent()->getBlock(); | |
if(!$block) { | |
return $this; | |
} | |
$store = Mage::app()->getStore(); | |
$storeId = Mage::app()->getStore()->getCode(); | |
if($block instanceof Mage_Adminhtml_Block_Widget_Grid_Massaction) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Varien_Data_Form_Element_Content extends Varien_Data_Form_Element_Abstract { | |
private $_defaults = array( | |
'block' => 'core/template', | |
'params' => '', | |
'template' => '', | |
); | |
public function __construct($attributes=array()) |
NewerOlder