g2lyon
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: how to prevent custom fields deletion ?@swayamtejwani
I now understand that as long as some posts are using a custom field key it cannot be deleted (without coding).
It’s sufficient for my needs.
Thank youJust tested 4.4.3: unresolved, same issue
Same issue on my site.
Is it resolved in 4.4.3 update?Thank you Marek,
Link instead of name would be a more robust way also for an other reason: If you have plenty of folders in your main folder you may want to reoganise them in subfolders. I noticed that this doesn’t change the link.
I understand that you cannot provide this option for the shortcode. I wanted to use the short code in fields (topic/google-drive-gallery-in-a-field/#post-12120202) but my site is still under construction, I will find a way with blocks.
I hope for good news!
- This reply was modified 5 years ago by g2lyon.
Forum: Themes and Templates
In reply to: [Twenty Twenty] style.css in Child Theme – No effectForum: Themes and Templates
In reply to: [Twenty Twenty] style.css in Child Theme – No effect@jarret,
Thanks for help
I tested selector as suggested, but it doesn’t work.To make it more clear, find below a copy of what I get from Google Chrome developpement tool:
element.style?{ color: rgb(255, 255, 255); } (index):41 body:not(.overlay-header) .primary-menu > li > a,?body:not(.overlay-header) .primary-menu > li > .icon, .modal-menu a, .footer-menu a, .footer-widgets a, #site-footer .wp-block-button.is-style-outline, .wp-block-pullquote:before, .singular:not(.overlay-header) .entry-header a, .archive-header a, .header-footer-group .color-accent, .header-footer-group .color-accent-hover:hover?{ color: #188513; } style.css?ver=0.1.0:10 body:not(.overlay-header) .primary-menu li a?{ color: red; }
1/ element.style? (highest priority) is from child-theme.js
2/ (index):41 (lower pririty) is from inline<style>
tag, probably added by some js script in 2020 as parent theme.
3/ style.css (lowest priority) is queued from child-theme.cssIn 2020 there is a text color selector. Then color is probably embedded in the
<style>
tag by some js.
As the inline<style>
tag is located after the style sheets its too late to modify the color in child-theme.css. Fortunately it works with child-theme.jsForum: Themes and Templates
In reply to: [Twenty Twenty] style.css in Child Theme – No effectFirst I grab some selectors from the elements attributes in html page. No one worked.
Then I took the top one from google Chrome developpement tool window:
body:not(.overlay-header) .primary-menu > li > a
Didn’t work in style.css but it works like a charm in jquery.
$('body:not(.overlay-header) .primary-menu > li > a').css('color','#FFFFFF');
It only affects the primary menu.- This reply was modified 5 years ago by g2lyon.
Forum: Developing with WordPress
In reply to: Alter taxonomy selector with Jquery@boatkung,
it works! thanks a lot, you are the best!Forum: Developing with WordPress
In reply to: Alter taxonomy selector with JqueryForum: Developing with WordPress
In reply to: Alter taxonomy selector with JqueryAhAh!
Hugh, you put me on the good way.
I confirm the problem comes from the dynamic loading,
it works with the.live()
method.
but doesn’t works with the.on()
method.
As per Jquery documentation.live
method is deprecated and we should use.on()
instead.
I have in mind that my problem is comming from a too hold version of Jquery in WP WP5.3 (v 1.11.4 while the last one is 3.4)
Is there a way to set the jquery version in WP without altering the core?- This reply was modified 5 years ago by g2lyon.
Forum: Developing with WordPress
In reply to: Alter taxonomy selector with JqueryI have already tested and retested
.on()
method without success.
May be the reason is that sidebar elements are loaded dynamically, so scripts enqueued withadmin_enqueue_scripts
dont have any effect.Forum: Plugins
In reply to: [Block Lab] Block Lab – css files in plugin – Not workingHello Luke,
It works! Thanks,
Anti slashes were coming from a copy/paste in the file property window.
Unfortunately I have to work on W10. This wouldn’t happen in Linux!.
Slashes vs anti slashes / Linux vs Windows
I guess I will not be the only one doing this mistake.But something remains unexplained for me: Why was it working with block.php files and not with block.css files?
Hello Marek,
Thanks for answer.
Blocks or short code let the user locate the gallery anywhere in the post while I want the gallery to stay only at the bottom of the post, and only one gallery per post.In the mean time I found a way with a couple of php lines in the content.php template, just after
the_content();
as follows :$folder_name = get_post_field('gdrive_folder_name'); $shortcode ='[sgdg path="'.$folder_name.'"]'; print 'My Gallery:'. apply_filters( 'the_content', $shortcode );
It works like a charm.
No need to enter the complete short code, only the folder name in the custom field.
If the user hasn’t knowlegde of the short code he will not use it,
and I disabled the block in the block manager.So far so good!
Your idea of using google drive API+some kind of lightbox is very good for sites in low performance server (my case). Thanks for the work!
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
- This reply was modified 5 years ago by g2lyon.
Forum: Plugins
In reply to: [Block Lab] Block Lab – css files in plugin – Not workingSome more tests:
Instead of moving the complete blocks directory from mytheme to myplugin I moved only the block.php and preview.php files.
The bolck.css files are remaining in mytheme
Then I applied the filter.
IT WORKS!!
My conclusion is that, even if you add filter, Block Lab does not look for css files in plugin, but only in theme.
I would prefer the complete set (templates+css) to stay together in the same place. For me block css belongs to the block design, not to site design. It works in this way for example in Drupal.
May be one more filter should be added? add_filter(‘block_lab_css_path’,’url_css_blocklab’ );Forum: Plugins
In reply to: [Block Lab] Block Lab – css files in plugin – Not workingSorry, new styling, easier to read
mychildtheme blocks myblock block.css block.php preview.php myotherblock etc… IT WORKS!(block displayed with styling) Then I moved to: myplugin blocks myblock block.css block.php preview.php myotherblock etc… IT DOES NOT (block displayed, but without styling)