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
$out = phpinfo2array(); // https://www.php.net/manual/ru/function.phpinfo.php#117961 | |
writeToLogFile( $out ); // https://gist.github.com/Robert-IMT/98d5e9f6aa86b8f922cf6196b80320a9 |
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
/** | |
* Write variable value to file | |
* | |
* @param mixed $data | |
* @param string $file | |
*/ | |
function writeToLogFile( $data, $file = 'tmp/log.txt' ) { | |
$developers = array( | |
'127.0.0.1', // localhost |
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
/** Scroll */ | |
::-webkit-scrollbar { | |
background-color: transparent; | |
width: 6px; | |
} | |
::-webkit-scrollbar-button { | |
background-color: transparent; | |
} | |
::-webkit-scrollbar-track { |
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
.error-404 #blink { | |
-webkit-animation: blink 2s linear infinite; | |
-moz-animation: blink 2s linear infinite; | |
animation: blink 2s linear infinite; | |
font-style: normal; | |
color: #FFF; | |
} | |
@-webkit-keyframes blink { | |
50% { color: rgb(255, 255, 255); } | |
51% { color: rgba(0, 163, 232, 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
jQuery( '#custom-phone input' ).bind( "change keyup input click", function() { | |
if( this.value.match( /[^0-9]/g ) ){ | |
this.value=this.value.replace( /[^0-9]/g, '' ); | |
} | |
}); |
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
$('.count').each(function () { | |
$(this).prop('Counter',0).animate({ | |
Counter: $(this).text() | |
}, { | |
duration: 4000, | |
easing: 'swing', | |
step: function (now) { | |
$(this).text(Math.ceil(now)); | |
} | |
}); |
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
div { | |
height:100%; | |
width:100%; | |
margin:0; | |
display:flex; | |
} | |
div > span { | |
margin:auto; | |
font-size: 2em; | |
} |
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 | |
$collection = $category->getProductCollection(); | |
$collection -> addAttributeToSelect(array('NAME_OF_ATTRIBUTE1','NAME_OF_ATTRIBUTE2')); | |
?> | |
<?php | |
foreach ( $collection as $_product ) { | |
echo $_product -> getNameOfAttribute(); | |
echo $_product -> getAttributeText('NAME_OF_ATTRIBUTE') ; | |
echo $_product -> getData('NAME_OF_ATTRIBUTE'); |
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
NOTE: | |
rename oc_ to prefix table | |
rename id1,id2 to ID products | |
=== | |
DELETE t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, t15 | |
FROM oc_product t1 | |
LEFT JOIN oc_product_attribute t2 ON(t1.product_id=t2.product_id) | |
LEFT JOIN oc_product_description t3 ON(t1.product_id=t3.product_id) |
NewerOlder