פלאגין לייק ושייר של פייסבוק מותאם לוורדפרס לעמוד פוסט

Read More »

הגדרת גודל תמונה עבור רשתות חברתיות YOAST

הגדרת גודל תמונה אידאלי עבור פייסבוק וואצאפ. ורשתות חברתיות. חשוב להגדיר גודל תמונה ל 300*300 לפי דרישת פייסבוק ווצאפ. ולאחר מכן לג'נרט את התמונות מחדש. פוסטים בחם תהיה בעיה ניתן להשתמש ב Facebook Developer

Read More »

Contact Form7 Strip

WPCF7 קונטקט פורם 7 בשורה אחת קוד קצר מיועד לאתרי ויז'ואל קומפוזר VISUAL COMPOSER

Read More »

פרלאקס באלמנטור

elementor paralax // PARALAX add_action( 'wp_enqueue_scripts', 'oceanwp_child_enqueue_parent_style' ); function jquery_parallax() { ?> <style>.parallax {transition: none !important;}</style> <script language="JavaScript" type="text/javascript"> ;(function($) { 'use strict' var testMobile;

Read More »

Css לאקספלורר

Explorer Hacks Css /* IE10 + */ @supports (-ms-accelerator:true) { .people .elementor-column-wrap.elementor-element-populated{display:block !important;} } @supports (-ms-ime-align:auto) { .people .elementor-column-wrap.elementor-element-populated{display:block !important;} }  

Read More »

מחיקת מוצרים נלווים בווקומרס

remove related products woocomerce function gs_remove_related_products() { remove_action( 'woocommerce_after_single_product_summary', 'woocommerce_output_related_products', 20 ); } add_action( 'init', 'gs_remove_related_products', 10 );  

Read More »

ביטול מחיקת טגים של אדיטור TIMCE

add_filter('tiny_mce_before_init', 'tinymce_init'); function tinymce_init( $init ) { $init['extended_valid_elements'] .= ', span[style|id|nam|class|lang]'; $init['verify_html'] = false; return $init; } אפשר טאג SPAN אפשר טאג STYLE אפשר טאג

Read More »

סניפט הנחות בווקומרס

// The product custom field – Frontend add_action( 'woocommerce_before_add_to_cart_button', 'custom_discount_price_product_field' ); function custom_discount_price_product_field() { global $product; $curs = get_woocommerce_currency_symbol(); // Currency symbol // Get the

Read More »

הוספת באנר מתחת לCONTENT

add_filter('the_content', 'gs_extra_content') ; function gs_extra_content ($content) { if(is_singular('post')): $extra_stuff = "<!– banner code in functions by Global Solution–>"; $extra_stuff .= "<div style='text-align: center;'><img style='width: 70%;'

Read More »

תיקון שדות ללא

<?php $cast_members = get_post_meta($post->post_parent, 'cast_members', true); ?> <p><?php echo wpautop($cast_members); ?></p> <?php endif; ?>

Read More »

קיצור טקסט של קסטום פילד

<?php $content = get_post_meta($post->ID, your_custom_field_meta, true); $trimmed_content = wp_trim_words($content, 15, '… <a href="' . get_permalink() . '">Read More</a>'); echo $trimmed_content; ?>  

Read More »

תיקון לפלאגין popup maker

תיקון להפצת הפופאפ לחלק העליון של האתר בעזרת CSS + תוספות #popmake-3901,#popmake-3918{background-color:#fff !important} .pum-container.popmake.theme-3883{ background:none; box-shadow: none; } .pum.pum-overlay { background: #2020208c; } html.pum-open.pum-open-overlay, html.pum-open.pum-open-overlay.pum-open-fixed

Read More »

מחיר לפני ואחרי מע"מ ווקומרס

לאחרונה עבדתי על פרוייקט בו הייתי צריך להטמיע מחיר של יחידה + מחיר לפני מע"מ ומחיר כולל מע"מ. /* PRODUCT CATEGORY PAGE */ remove_action( 'woocommerce_after_shop_loop_item_title','woocommerce_template_loop_price',

Read More »

כיבויי ENDPOINT משתמשים ב WP RESTAPI

הסניפט הבא מאפשר לכבות נקודת קצה של רשימת משתמשים, מבחינתי מצאתי לנכון לכבות אותו מאחר הנקודת קצה הנ"ל מאפשרת להציג בגלויי את רשימת המשתמשים באתר

Read More »

ווקומרס קטגוריות

הצגת קטגוריות ריקות של ווקומרס // Show Empty Categories add_filter( 'woocommerce_product_subcategories_hide_empty', 'hide_empty_categories', 10, 1 ); function hide_empty_categories ( $hide_empty ) { $hide_empty = FALSE; //

Read More »

קביעת עמודות למוצרים

// Change number or products per row to 3 add_filter('loop_shop_columns', 'loop_columns'); if (!function_exists('loop_columns')) { function loop_columns() { return 4; // 3 products per row }

Read More »

החלפת אימייל סטרינג לקליקבל

סקריפט קטן ההופך כל אימייל סטרינג לקליבל, מיועד להחלפת האימיילים שיהיו לחיצים באתר, שימוש עיקרי באתרים בהם כבר קיימים אימיילים סטרינגיים $().ready(function() { var regEx

Read More »

עמודת תמונה ראשית ברשימת פוסטים

עובד גם בטקסונומיות אישיות // GET FEATURED IMAGE function ST4_get_featured_image($post_ID) { $post_thumbnail_id = get_post_thumbnail_id($post_ID); if ($post_thumbnail_id) { $post_thumbnail_img = wp_get_attachment_image_src($post_thumbnail_id, 'featured_preview'); return $post_thumbnail_img[0]; } }

Read More »

מדיות לIE

IE10+ @media screen and (-ms-high-contrast: active), (-ms-high-contrast: none) { selector { property:value; } } IE6,7,9,10 @media screen and (min-width: 640px), screen\9 { selector { property:value;

Read More »

פייסבוק פיקסל

// Include CODE FOR facebook pixel function facebook_pixel(){ ?> <!– Facebook Pixel Code –> <script> !function(f,b,e,v,n,t,s) {if(f.fbq)return;n=f.fbq=function(){n.callMethod? n.callMethod.apply(n,arguments):n.queue.push(arguments)}; if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0'; n.queue=[];t=b.createElement(e);t.async=!0; t.src=v;s=b.getElementsByTagName(e)[0]; s.parentNode.insertBefore(t,s)}(window,document,'script', 'https://connect.facebook.net/en_US/fbevents.js'); fbq('init', '198811724210153');

Read More »

איפוס PHP CACHE שרת

1. יוצרים קובץ בכל שם clearcache.php לתוכו מזינים את הפקודה הנ"ל <?php opcache_reset(); ?> 2. ניגשים אל הקובץ דרך הדפדפן. 3. מרפרשים והקאש נעלם. How To

Read More »

שימוש בפונקצייה JS

$(document).ready(function(){ // Here we have jQuery(document) firing off the ready event // which executes once the DOM has been created in // order to ensure

Read More »

שימוש בשורטקודים בכל מקום

add_filter( 'widget_text', 'shortcode_unautop'); add_filter( 'widget_text', 'do_shortcode'); add_filter( 'comment_text', 'shortcode_unautop'); add_filter( 'comment_text', 'do_shortcode' ); add_filter( 'the_excerpt', 'shortcode_unautop'); add_filter( 'the_excerpt', 'do_shortcode'); add_filter( 'term_description', 'shortcode_unautop'); add_filter( 'term_description', 'do_shortcode'

Read More »

הוספת פונט ב CSS

@font-face { font-family: 'Gilroy'; src: url('fonts/Gilroy-Regular.eot'); src: local('fonts/Gilroy Regular'), local('Gilroy-Regular'), url('fonts/Gilroy-Regular.eot?#iefix') format(’embedded-opentype'), url('fonts/Gilroy-Regular.woff') format('woff'), url('fonts/Gilroy-Regular.ttf') format('truetype'); font-weight: normal; font-style: normal; }  

Read More »

overlay Background CSS

.custom-header-media:before { background: -moz-linear-gradient(to top, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.3) 75%, rgba(0, 0, 0, 0.3) 100%); background: -webkit-linear-gradient(to top, rgba(0, 0,

Read More »

CSS RESET

html, body{ max-width: 100%; overflow-x: hidden; } } *:focus,*{ outline:none; }  

Read More »

WPCF7 קונטקט פורם 7 בשורה אחת

סטריפ קונטקט פורם 3 עמודות <div class="gs-contact-form"> [response] <div class="form-horizontal"> <div class="col-md-3 col-sm-12 form-col"> [text* your-name class:form-control class:form placeholder "שם"] </div> <div class="col-md-3 col-sm-12 form-col">

Read More »

מציאת קורדינטות לפי כתובת

function get_lat_long($address){ $address = str_replace(" ", "+", $address); $json = file_get_contents("http://maps.google.com/maps/api/geocode/json?address=$address&sensor=false&region=$region"); $json = json_decode($json); $lat = $json->{'results'}[0]->{'geometry'}->{'location'}->{'lat'}; $long = $json->{'results'}[0]->{'geometry'}->{'location'}->{'lng'}; return $lat.','.$long; } $address =

Read More »

יוזר אגנטס סלקטור ב CSS

html[data-useragent*='Chrome/40.0'] body { background-color: tan; } html[data-useragent*='Firefox/35.0'] body { background-color: salmon; } html[data-useragent*='Safari/600.3'] body { background-color: deepskyblue; } html[data-useragent*='Android'] body { background-color: silver; } html[data-useragent*='Android/2.1']

Read More »

תבניות עמוד לCPT

<?php /* Template Name: Full-width layout Template Post Type: post, page, product */ // … your code here Post Type Templates in 4.7

Read More »

שליטה בקישור ANCHOR ו Scroll

מיועד לאתרים שיש בהם סקרול שמוביל לאנקור מסויים פותר את בעיית העצירה והמיקום של הסקרול .anchor { display:block; padding-top:100px; margin-top:-100px; }  

Read More »

CSS שימושי

ביטול לחיצה על תמונה ותכונה PRETTY PHOTO במובייל בתבניות מבוססות ויז'ואל קומפוזר @media all and (max-width: 479px) { .vc_single_image-wrapper.prettyphoto { pointer-events: none; } } ניתן

Read More »

פתיחת תבנית בת Child Theme

פתיחת תבנית בת מומלצת לכל אתר שבו יהיו שינויי קוד כמו CSS ו JS על מנת לשמור את הקוד מפני דריסה שמתרחשת בעידכון חדש שיוצא לתבנית

Read More »

הוספת מחליף שפות ידנית תוסף Polylang

בעזרת הסניפט הבא אפשר להוסיף את מחליף השפות בכל אזור באתר ולקסטם אותו בעזרת פקודות שניתן להזריק לפונקצייה, אפשר להשתמש בנוסף למחליף השפות הקיים שבתפריט

Read More »

פקודות מאקרו

העמוד לא מכיל את פקודת המקרו. זאת הודעת שגיאה שמתקבלת עם לא נעשתה השלמת התקנה לאחר התקנת תוסף ווקומרס. לפעמים ישנה בעיה אם התבנית או

Read More »

הוספת תפריט ייחודי בוורדפרס

function wpb_custom_new_menu() { register_nav_menu('my-custom-menu',__( 'My Custom Menu' )); } add_action( 'init', 'wpb_custom_new_menu' ); http://www.wpbeginner.com/wp-themes/how-to-add-custom-navigation-menus-in-wordpress-3-0-themes/

Read More »

פילטר לכותרות של וידג'ט

function prefix_filter_widget_title_tag( $params ) { $params[0]['before_title'] = '<div class="widget-title widgettitle">'; $params[0]['after_title'] = '</div>'; return $params; } add_filter( 'dynamic_sidebar_params' , 'prefix_filter_widget_title_tag' ); פילטר מעולה לשינויי כותרות

Read More »

פונקצייה להטמעת אנליטיקס באתר וורדפרס פוטר

<?php // Include CODE FOR GOOGLE ANALYTICS Tracking function google_analitics_code(){ ?> <!– CODE FOR GOOGLE ANALYTICS –> <script> (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); ga('create', 'UA-656',

Read More »

זום על אלמנט

.item img { max-width: 100%; -moz-transition: all 0.3s; -webkit-transition: all 0.3s; transition: all 0.3s; } .item:hover img { -moz-transform: scale(1.1); -webkit-transform: scale(1.1); transform: scale(1.1); }

Read More »

הוספת קלאס לקונטקט פורם 7

לפעמים יש צורך להוסיף קלאס או איידי כדי להבדיל את הטופס שלנו או לעצב אותו [ title="Contact form 1" html_id="contact-form-1234" html_class="form contact-form"]

Read More »

עידכון שינוי טקסט, תבנית או ווקומרס

פונקצייה מעולה לשינויי תוכן / טקסט/ סטרינגים בעיקר שינויי כפתורים שיניי כותרות בתבנית שינויי כותרות בווקומרס שינויי סטרינגים add_filter('gettext', 'translate_reply'); add_filter('ngettext', 'translate_reply'); function translate_reply($translated) {

Read More »