Skip to content

Instantly share code, notes, and snippets.

View wolinka's full-sized avatar

Wolinka wolinka

View GitHub Profile
@wolinka
wolinka / homebrew-path.sh
Last active January 6, 2024 19:28
Homebrew path
(echo; echo 'eval "$(/opt/homebrew/bin/brew shellenv)"') >> /Users/mac-kullanici-adi/.zprofile
eval "$(/opt/homebrew/bin/brew shellenv)"
@wolinka
wolinka / homebrew.sh
Last active January 6, 2024 19:19
Homebrew sh
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
<?php
/**
* @snippet Belli Ürün Sayfalarında WooCommerce Sepete Ekle Butonu Kaldirma
* @sourcecode https://blog.wolinka.com/?p=164
* @author Ozlem Cimen
* @compatible WooCommerce 4.0.1
**/
function wlnk_remove_add_to_cart_button_for_custom_products() {
if ( is_product(array('5') ) {
add_filter( 'woocommerce_is_purchasable', '__return_false' );
@wolinka
wolinka / woocommerce_billing_custom_checkout_fields.php
Last active January 4, 2023 19:15
WooCommerce Fatura Detayları Düzenleme
<?php
/**
* @snippet WooCommerce Fatura Detayları Nasıl Düzenlenir?
* @sourcecode https://blog.wolinka.com.tr/?p=167
* @author Wolinka - WooCommerce Uzmani
* @compatible WooCommerce 4.0.1
**/
// Fatura Adresi kısmına vergi dairesi ve vergi numarası özel alanlarını ekler.
function wlnk_billing_custom_checkout_fields( $fields ) {
@wolinka
wolinka / woocommerce_new_customer_admin_notification.php
Last active January 4, 2023 18:59
WooCommerce Yeni Müşteri Kaydı E-Posta Bildirimi
<?php
/**
* @snippet WooCommerce: Yeni Müşteri Kaydı E-Posta Bildirimi
* @sourcecode https://blog.wolinka.com.tr/?p=181
* @author Wolinka - WooCommerce Uzmani
* @compatible WooCommerce 4.0.1
**/
function wlnk_new_customer_admin_notification( $customer_id ) {
wp_send_new_user_notifications( $customer_id, 'admin' );
}
@wolinka
wolinka / wolinka_is_product_remove_add_to_cart_button.php
Last active April 1, 2022 17:37
Belli Urun Sayfalarında WooCommerce Sepete Ekle Butonu Kaldirma
<?php
/**
* @snippet Belli Urun Sayfalarinda WooCommerce Sepete Ekle Butonu Kaldirma
* @sourcecode https://www.wolinka.com/tr/?p=806
* @author Ozlem Cimen
* @compatible WooCommerce 4.0.1
**/
function wolinka_is_product_remove_add_to_cart_button() {
if ( is_product(array('65,51')) ) {
add_filter( 'woocommerce_is_purchasable', '__return_false' );
@wolinka
wolinka / index.html
Created February 4, 2022 09:42
Yapım aşamasında html sayfası
<!doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title>wolinka.com.tr</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
@wolinka
wolinka / woocommerce_remove_add_to_cart.php
Last active November 6, 2021 09:27
WooCommerce Sepete Ekle Butonunu Kaldırma
<?php
/**
* @snippet WooCommerce Sepete Ekle Butonunu Kaldırma Fonksiyonu
* @sourcecode https://blog.wolinka.com.tr/?p=164
* @author Wolinka - WooCommerce Uzmani
* @compatible WooCommerce 4.0.1
**/
add_filter( 'woocommerce_is_purchasable', '__return_false'); // Satin alma islevini devre disi birakir ve basit urunlerde sepete ekle butonunu kaldirir.
remove_action('woocommerce_single_variation', 'woocommerce_single_variation', 10); // Varsyonlu urunlerde fiyati kaldırır.
remove_action('woocommerce_single_variation', 'woocommerce_single_variation_add_to_cart_button', 20); // Varyasyonlu urunlerde sepete ekle butonunu kaldirir.
@wolinka
wolinka / woocommerce_remove_add_to_cart.php
Created November 6, 2021 09:21
WooCommerce Sepete Ekle Butonunu Kaldırma
<?php
/**
* @snippet WooCommerce Sepete Ekle Butonunu Kaldırma Fonksiyonu
* @sourcecode https://blog.wolinka.com.tr/?p=164
* @author Wolinka - WooCommerce Uzmani
* @compatible WooCommerce 4.0.1
**/
remove_action( 'woocommerce_after_shop_loop_item', 'woocommerce_template_loop_add_to_cart', 10 ); // Magaza ve Arsiv
remove_action( 'woocommerce_single_product_summary', 'woocommerce_template_single_add_to_cart', 30 ); // All single
remove_action( 'woocommerce_simple_add_to_cart', 'woocommerce_simple_add_to_cart', 30 ); // Basit urunler icin
@wolinka
wolinka / wordpress_classic_widgets.php
Created August 10, 2021 18:37
WordPress Bilesenleri Eski Haline Getirme Fonksiyonu
<?php
/**
* @snippet WordPress Bilesenleri Eski Haline Getirme Fonksiyonu
* @sourcecode https://blog.wolinka.com.tr/?p=804
* @author Wolinka - WordPress Uzmani
* @compatible WordPress 5.8
**/
// Disables the block editor from managing widgets in the Gutenberg plugin.
add_filter( 'gutenberg_use_widgets_block_editor', '__return_false', 100 );