WordPress 101 - Part 9: Edit the query_posts with WP_Query

แชร์
ฝัง
  • เผยแพร่เมื่อ 23 ธ.ค. 2024

ความคิดเห็น • 180

  • @igoroleinic688
    @igoroleinic688 7 ปีที่แล้ว +26

    Best WordPress tutorials! Alessandro, thank you for your job

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว +3

      Thank you so much :D

  • @towhidulislam4096
    @towhidulislam4096 6 ปีที่แล้ว +2

    You have a super power to teach complex things in easy way. Great teacher for WP!

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Ah, thank you so much :D

  • @omarch.9202
    @omarch.9202 7 ปีที่แล้ว +5

    The best WordPress tutorials as always, your youtube channel became my Netflix :D.

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Wonderful, I'm glad you found my videos :D

  • @pirmecra2873
    @pirmecra2873 8 ปีที่แล้ว +1

    You are really super man! You are talking better than professors in the university !!!

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Pir Mera Oh wow, I don't really think so, my english is really bad.
      Thank you so much for this amazing comment :D

  •  9 ปีที่แล้ว +1

    As i said on twitter, you change my view of wordpress with those $args :D
    Keep going man. Those premium wp theme tuts are something to bookmark for a lifetime :)))

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +Eldin Rodić (Eldininjo) Awesome, thank you so much for your enthusiasm :D

  • @benjymouse7701
    @benjymouse7701 7 ปีที่แล้ว +3

    Alessandro I'm absolutely blown away by how good your tuts are and I'm only 9 vids in! Going to watch them all and subscribed. Thank you so much for your time. Looking forward to your linux build too :-) cheers!

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Hey, thank you so much for watching my videos and welcome tot he community.
      You have many many hours of coding tutorials ahead, enjoy, and please don't hate my voice :P
      Happy Coding

  • @lantoaphatphap-f9r
    @lantoaphatphap-f9r ปีที่แล้ว +1

    Thank you alecaddd, your videos really a treasure to me, I'm learning Wordpress for my change of a carreer next month, and these videos helping me so much. My appreciate to you.

    • @alecaddd
      @alecaddd  ปีที่แล้ว +1

      I’m glad my videos are helping you. Good luck!

  • @jellycoding
    @jellycoding 9 ปีที่แล้ว +4

    Awesome !!! You are the man of 2015! This is super good!

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว +3

      +jellycoding Pushing forward to remain a man also in 2016 :D

    • @MrGunz0DZ
      @MrGunz0DZ 7 ปีที่แล้ว +1

      2017 still the man :D

  • @nasrockz1
    @nasrockz1 4 ปีที่แล้ว +2

    Your tutorial in here are way better than those that I bought in udemy !

    • @alecaddd
      @alecaddd  4 ปีที่แล้ว

      Never buy stuff from Udemy :P

  • @alishreef6249
    @alishreef6249 8 ปีที่แล้ว +1

    :) you are soooooooooooo great in explaining the point , greeting from Egypt and do not stop

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +2

      I'll never stop, and thank you so much!

  • @nosracnotyep
    @nosracnotyep 6 ปีที่แล้ว +1

    I am really enjoying these tutorials. Thanks for these Alessandro.

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      You're very welcome :D

  • @navidgamingstorts
    @navidgamingstorts 8 ปีที่แล้ว +1

    I have been looking for good video tutorials for a long time. Your presentation has clearified many yhings. As a beginner anyone can get from your videos. Thanks- Md. Seraj Uddin

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Mohammad seraj seraj No need to search further :D
      Happy you found me, welcome and Happy Codgin!

  • @matthewallbright8064
    @matthewallbright8064 7 ปีที่แล้ว +1

    So far this is better than the tuts on pluralsight.

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Thank you so much :D

  • @TheDrajvon
    @TheDrajvon 7 ปีที่แล้ว +1

    Wow! Your tutorials are the best! I thought wordpress is difficult to understand. Now I can tell WordPress is SUPER EASY :D

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว +1

      Happy to hear that :D

  • @swapondiary
    @swapondiary 9 ปีที่แล้ว +2

    You are just awesome for beginner. I have just want to start WP but always don't get interest to continue it. But now I love to continue your tutorial and I think the result will be fruitful for me.

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      Awesome, thanks for the comment and I am happy for you!

  • @BHFJohnny
    @BHFJohnny 6 ปีที่แล้ว +1

    Going through your tutorials. They are really good value. Thank you, Alessandro, for doing this for us.

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      You're very welcome, thanks for watching

  • @MuadDibCameForYou
    @MuadDibCameForYou 8 ปีที่แล้ว +1

    Alessandro, thank you so much for your tutorials! Your explanations are so good and simple that anyone is able to understand them. Greetings from Russia and if I will be somewhere around your place - I ow you a pack of beer (of course if you love it, otherwise it will be any beverage that you order)

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      I love beer!
      Thank you so much for watching and welcome to the community

  • @Mohanraj-xe4dd
    @Mohanraj-xe4dd 7 ปีที่แล้ว +1

    Great lession, awesome teaching

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Thank you so much

  • @TheNightWolf95
    @TheNightWolf95 5 ปีที่แล้ว

    This is very powerful! Enjoyed watching it and learning from it. What I try to do now...is to exclude special posts in a category from a certain page

  • @blurfunn
    @blurfunn 8 ปีที่แล้ว +1

    It's nice video,thanks. I have a question, when you create page-home.php how could this page turn to (override) index.php ?(I mean which one is real front page file? page-home.php or index.php? ) very confuse. at 9:23

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +1

      Thank you so much for following.
      The page-home.php as higher priority on index.php if the SLUG of one of your pages is "home", so something like "yoursite.com/home"
      Index.php is usually the location of the post loop, but in the settings you can assign the first page to be another page other than the post loop. So a custom page associated with a unique slug has higher priority.
      You can also create a page called front-page.php that WP will use no matter what's the name of the page you set as first page.

    • @blurfunn
      @blurfunn 8 ปีที่แล้ว

      Thank you very much!

  • @DanielLevinedigitalpixel
    @DanielLevinedigitalpixel 5 ปีที่แล้ว +1

    Thank you for your tutorials man!

    • @alecaddd
      @alecaddd  5 ปีที่แล้ว

      Cheers

    • @DanielLevinedigitalpixel
      @DanielLevinedigitalpixel 5 ปีที่แล้ว

      @@alecaddd just a quick question, I have a captcha implemented on my contact form 7, however I am still getting spam emails, is there any way I can correct this so I dont receive spam emails?

  • @madmanww
    @madmanww 8 ปีที่แล้ว +3

    Great tutorial! Learned some very important concepts.

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +1

      Glad to hear that.
      Happy Coding!

  • @wireinet
    @wireinet 8 ปีที่แล้ว +2

    oh...this is so hard...but this is very powerful! Thank you for knowledge

  • @JoshuaPickenpaugh
    @JoshuaPickenpaugh 8 ปีที่แล้ว +1

    Great tuts! Thanks for all of these!

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Joshua Pickenpaugh You're welcome, thank you for following!

  • @JhonChrizelGodmalin
    @JhonChrizelGodmalin 7 ปีที่แล้ว +1

    Hi Alessandro! Thanks for your tutorials, I finally get my hands into wordpress theme development. I just want to ask if is it possible to create something like what you did in the last part of this video without knowing what category is going to be used?

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Hi, thanks for watching.
      You can for sure! The first approach that comes to my mind is to set a custom meta box for the categories select which category you want to use. In this way, you'll have an admin related control to manage this option, without bounding the query post to a specific category ID.
      Cheers

  • @DanielEliasKana
    @DanielEliasKana 9 ปีที่แล้ว +2

    Just what i needed :) thank you!

  • @unseenforce2790
    @unseenforce2790 8 ปีที่แล้ว +1

    bro i watch this tutorial 5months ago w/o head set and doing a lot of error no time to fix then when i re-watch it again w/ head set and hear ur voice. im am doing well now w/o error.. thank you bro! ive learn a lot.
    i dont know if this is bug.
    for example i make a 2 types of template name for get_postformat
    example1-aside
    example2-aside
    the old is the example 1. when i use the new example2 in home-page using wp_query, that new will not display i dont know why.

  • @idiartt
    @idiartt 5 ปีที่แล้ว

    This is golden! Thank you for sharing your knowledge.

  • @Wendym0906
    @Wendym0906 8 ปีที่แล้ว +1

    love this!!! can i ask you what theme your using i like the color format. tx

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      I'm using Panic Coda and the theme it's a personal alteration of Monokai

  • @stugoldberg5913
    @stugoldberg5913 9 ปีที่แล้ว +1

    Great Tutorials. Keep up the great work! So clear and concise.

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +Stu Goldberg Thank you for following

  • @fancyAlex1993
    @fancyAlex1993 6 ปีที่แล้ว

    Hi, if i want to let users to filter posts based on year, that means when user chooses 2018 on front end, the posts from 2018 will be loaded, do we use ajax with wp_Query for this kind of function?

  • @davidk2594
    @davidk2594 9 ปีที่แล้ว +1

    Hey Alessandro! Great tutorials!
    Just wondering- are you translating the ampersand (&), which means "and" into the Italian "e", or does it just look like an "e'?

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +David King Yes, I realized later that calling ampersand (&) character "e" is wrong, I'm sorry >_>

  • @kramlig90
    @kramlig90 9 ปีที่แล้ว +1

    sir can you help how to get the post only the subcategory of category parent sir, .

  • @ck0024
    @ck0024 5 ปีที่แล้ว +1

    *God* level tutorial.

  • @bhaweshthapa4672
    @bhaweshthapa4672 3 ปีที่แล้ว

    Great tutorials. I have one issue, we have created the page-home.php file but any code written on it is not working. I have to write the code on the index.php page as WordPress is displaying that as my default front page.

  • @right-thinking2903
    @right-thinking2903 6 ปีที่แล้ว

    Alessandro! Great tutorials! Have one question... I am following along to the t, but my site kinda looks different than yours. My navigation menu is different and my sidebar too. I have added some other code for the background, but that is really it. Can you help please, would really like to have a menu like yours. I am using BootStrap v4.2.x

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      I was using Bootstrap 3.3.7 during these videos. It doesn't really matter how the front-end looks as you can easily change it with another framework or make it work with the new version of bootstrap by updating the html markups and css classes.

  • @minhvan8599
    @minhvan8599 9 ปีที่แล้ว +1

    Hi Ales ! I'm doing the same things but it is giving me a headache , throwing call to undefined function WP_Query() but weirdly if i replace it by query_posts , it works .

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +Minh Van Hi, and thanks for the comment. Can you paste me your code where you call the WP_Query()? So I can take a look and check for any mistake.
      Also, if you can, please take a look at the GitHub repo with the specific folder of the lesson and compare my code with yours to see any typo.
      Cheers

    • @minhvan8599
      @minhvan8599 9 ปีที่แล้ว

      +Alessandro Castellani
      Thanks for the reply .
      It is located in category.php .

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      So, I don't seem to find a mistake at first sight, but there are a couple of weird things.
      First you call a statement after the query_posts($args)
      if(have_posts()):
      wp_redirect(get_site_url());
      endif;
      But then you have another if(have_posts()):
      Be careful because if both this declarations are true, the system will attempt a redirect and to print the posts at the same time.
      Also, at the beginning before the heard, I suggest you to switch your function with this: get_cat_ID( $cat_name )
      To retrieve the category ID, if is what you're trying to do.
      Can you show me the code where you were using the WP_Query() class?

    • @minhvan8599
      @minhvan8599 9 ปีที่แล้ว

      +Alessandro Castellani
      Yes thanks for your help , i just removed the fancy 1st if .
      what I`m trying to do now is to get posts by category id with the query variable .
      it works fine , but if i change the middle snippet like workupload.com/file/xDdpmkEN . Ive uploaded for you to look easier . it throws called to undefined function WP_Query() . I ve been searching for this , all the topics tell me that the $args have invalid key or to put on wp_reset_postdata() .

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      Uh, I think I found the mistake. In the $args array, the post type key is 'post_type' not 'type'.
      Change that and check.

  • @J4si3k1992
    @J4si3k1992 8 ปีที่แล้ว

    how create one query from category and custom post type? for example i've got custom post type "car" and category "bus, bicycle" and i would like show it in one loop. How create table $args?

  • @pawpaaj
    @pawpaaj 7 ปีที่แล้ว +1

    Great Tutorials. You explain it very well and it looks so easy to me right now. I just wonder how to make it work with pagination. For example if I have 10 posts but I want to display 5 on the page = 5 posts per 1 pagination page. And of course I have no idea how to show pagination by using build-in functions of wordpress (is that even possible?). Do you have any tutorials on that topic? Thanks!
    Update: okay, after writing this comment I've realized that it's going to be covered in these series so it's great! I'm going to make it through to reach pagination topic, thanks again!

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว +1

      Yes, it's explained in this series, and also in the next one.
      Keep watching and happy coding!

    • @pawpaaj
      @pawpaaj 7 ปีที่แล้ว +1

      For sure I will, thanks :)

  • @emilielemoine
    @emilielemoine 6 ปีที่แล้ว

    Hi Alessandro ! Thank you for that tutorial it's really nice. I don't succeed to send parameters from my template page to another page (via $_post as I am used to do). Is wp_query that I need to use to do so in the wordpress environment ? (for your information I just want to send values from one page to another not getting data from the database)

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Check my source code on Github to see if you have any typos.
      I have an example about what you need in my source code, and in these videos.

  • @ShahrukhKhan-vp3cg
    @ShahrukhKhan-vp3cg 6 ปีที่แล้ว +1

    Hey Alessandro! I am getting error in header like my header navigation pages are not shown directly. They are within the toggle navigation button. When I press it then it shows the header navigation pages. Kindly help me in this matter! Thanks in advance!

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      You can check my source code on GitHub if you're using Bootstrap v3.3.4 like I did. If you're using Bootstrap v4, the syntax is slightly different and you need to update it

    • @ShahrukhKhan-vp3cg
      @ShahrukhKhan-vp3cg 6 ปีที่แล้ว

      @@alecaddd Now I get it thanks. And I want to know that when we inspect our website and change css on runtime in the bottom-left corner of our window, the style won't change. Why is it so? I want to change it at runtime.

  • @nhatminhtran7917
    @nhatminhtran7917 8 ปีที่แล้ว +1

    great teaching master !!!

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      Thank you so much :D

  • @ajit5279
    @ajit5279 9 ปีที่แล้ว +1

    how do i can customize content or content-aside.php to appear as yours appearing

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +Cartoon Boy Hi, thanks for your comment. I'm not sure what do you mean by customizing. If you follow the entire series you will understand how to style the files differently. I used bootstrap as my CSS framework. Cheers

  • @bakinto
    @bakinto 7 ปีที่แล้ว +1

    Two words : You're awesome

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว +1

      awww, thank you 😍

  • @taranoori3660
    @taranoori3660 6 ปีที่แล้ว

    Dear Alessandro, Thank you for a great tutorial. I have som problem with the thumbnail. The text and the thumbnail picture crashes when i minimize the window. I use bootstrap 4. Have you any idea why?

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Hi, thanks for watching my tutorials.
      In these videos, I'm using Bootstrap 3, I think the CSS classes are slightly different from the new version. That could be the problem.
      Anyway, you can check my source code on Github and see if you have any typos.
      Cheers

    • @taranoori3660
      @taranoori3660 6 ปีที่แล้ว

      Thank you for the fast reply. Do you think I should change to v.3 or is there any cons with using bootstrap v.3 instead of v.4?
      Best regards,

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      V3 is not bad and a lot of websites still use it. The major thing you'll miss from v4 is the new grid system built on flexbox, but if you never used flexbox, is not a big deal.
      Cheers

  • @ricardoalvarez-correa8860
    @ricardoalvarez-correa8860 7 ปีที่แล้ว

    Hi Alessandro, I am following your series to learn how to use WP, so far is great, I have learned a lot! but I have a problem, I want to insert images into the theme itself so that I can edit them later, but I cannot find that information nowhere in the internet or I don't understand it, can you tell me how it is done or refer me to a website?

    • @jasonlab4938
      @jasonlab4938 7 ปีที่แล้ว

      how do you mean into the theme? to display an image when you are selecting from themes? like a clip of your theme?

  • @BhavShashank
    @BhavShashank 8 ปีที่แล้ว +1

    So, It was going great, but now am stuck...first thing I didn't created a separate page for blog (i guess) and I am working in index.php, now I made a file page-home.php set my front page to home...checked its slug its too set at home, and now still I didn't get the latest post on my home page. Too I tried typing the URL but it leads me to a blank page. Any guess >??

    • @MrBlackephatch
      @MrBlackephatch 6 ปีที่แล้ว

      make sure your page-home.php is in your theme folder

  • @yukasung
    @yukasung 6 ปีที่แล้ว +1

    Great tutorial

  • @yuriymiroshnychenko5446
    @yuriymiroshnychenko5446 9 ปีที่แล้ว

    Thanks for a very useful videos!

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว +1

      Thank you for following it!

  • @ckgringoblogger9170
    @ckgringoblogger9170 8 ปีที่แล้ว

    Hey Alessandro, whats up man?
    Thank you for the amazing class, i've been learning a loooot non stop.
    i got a problem, with my theme, when i test locally my template works great but when i upload my theme i activate and when i create a page and click update i got a blank page in my admin area then i delete or change my theme, my back end works again, im following exactly like the lessons.

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +1

      Hi, thank you so much for following.
      Did you try to activate your WP_DEBUG and see if you have any errors?

  • @paoloburcer1750
    @paoloburcer1750 8 ปีที่แล้ว +1

    this part is amazing....thanks thanks

  • @TheEli1963
    @TheEli1963 7 ปีที่แล้ว +1

    Very Nice Tutorials
    question sir, my dropdown navigation is now not working on the page-home.php.

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Check my source code on Github and see if you have any typo.

    • @loickiri
      @loickiri 7 ปีที่แล้ว

      i had the same but i just forgot to close a bracket somewhere... ^^

  • @VasilisKar
    @VasilisKar 8 ปีที่แล้ว +1

    Many thanks Aless..

  • @corneliasilvano5341
    @corneliasilvano5341 6 ปีที่แล้ว

    Good day, how will you form this menus, this are not in your part 8 tutorial. Thanks

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      I built it during the Live Development session: th-cam.com/video/OSYbTkzuyDg/w-d-xo.html

  • @heatherlynnlizama
    @heatherlynnlizama 8 ปีที่แล้ว +1

    Very detailed! Great videos!

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Heatherlynn L Thank you so much!

  • @haowu7719
    @haowu7719 7 ปีที่แล้ว

    好人啊,教程非常的好,谢谢

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      I guess you're complimenting me for the tutorial...at least that's what the translator wrote :D

  • @divikingdom6937
    @divikingdom6937 8 ปีที่แล้ว +1

    thanks, Alex. Nice tutorial

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Sailor Abood Thanks for watching!

  • @noorsultan2545
    @noorsultan2545 8 ปีที่แล้ว

    multo graci , bu i have issue with the page template doesn't display in my home page any help thank you great tutorial

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      Is your home page slug identical to the page name?

  • @fatimajahaf1412
    @fatimajahaf1412 7 ปีที่แล้ว +1

    thank you for all this great videos,,however any plans for oop and mvc tutorials any time soon ,,plz T-T ... u have an amazing way to make things simple and covering all needed infos ,,

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Hi, thank you so much for watching my tutorials.
      I'm currently doing the Plugin development series in OOP. I'm teaching the basics of OOP while showing how to build a plugin, I hope you'll like it.
      In February I should start a Laravel tutorial series for beginners, I hope you'll stick around and subscribe :D

    • @fatimajahaf1412
      @fatimajahaf1412 7 ปีที่แล้ว

      Alessandro Castellani thanks, ,so can we jump into laravel without or that is included in the plug-ins ?

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      The Laravel series will be something completely on its own, disconnected from the WordPress series.
      Knowing PHP OOP would be definitely helpful tho

    • @fatimajahaf1412
      @fatimajahaf1412 7 ปีที่แล้ว

      Alessandro Castellani sorry i missed writing MVC without mvc...anyways i am so grateful for ur time replying my questions..really thank you

    • @fatimajahaf1412
      @fatimajahaf1412 7 ปีที่แล้ว

      I can't wait to learn laravel frm ur vedios. .hopefully won't take long ^^

  • @isanlagunzad9348
    @isanlagunzad9348 6 ปีที่แล้ว

    Hello can i ask how to add widgets like front page 1, front page 2, and the footer 1 ,footer 2 ,footer 3?

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Watch my premium theme development playlist on my channel and you'll learn everything you need

  • @kaiserthegreat
    @kaiserthegreat 6 ปีที่แล้ว +1

    Just an FYI for anyone following this, my imported Wordpress "content" for purposes of filling my page with something had some posts marked as "sticky" which screwed up the "only show my latest post" idea of this tutorial. It was showing my latest post plus the three sticky posts. Removing the sticky checkmark and everything works fine.

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Thanks for sharing your issue, and I'm glad you solved it :D

  • @angelicakirana1500
    @angelicakirana1500 8 ปีที่แล้ว +1

    my home doesnt have a slug it just says /myblog, i try to use the number which is 5. so i try page-5.php but it still doesnt work i use page-home.php as well and also doesnt work, pls help

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      What's the permalink that appears underneath the Title filed of your home page in your admin panel when you edit that page?

    • @angelicakirana1500
      @angelicakirana1500 8 ปีที่แล้ว

      Http://localhost:8888/myblog/
      And i cant edit the permalink/slug

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      did you set this page as front page in the Reading settings? What's the name of this page? Is /myblog/ your editable slug?

    • @angelicakirana1500
      @angelicakirana1500 8 ปีที่แล้ว

      yes i set it as my front page in the reading setting, the name of the page is home. and no the permalink is not editable

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +1

      ok, that's why. If you set a page as Front Page, WP will remove the permalink. To handle that page you can create a file called front-page.php. This file will be used for whatever page you set a Front Page in your settings.

  • @jaylab1460
    @jaylab1460 7 ปีที่แล้ว

    +Alessandro Castellani, I'm having an issue with implementing the get_terms() function to jjust display categories instead of posts, I saw one user with the same question and you referred him to the codex page of WP. However is simply don't understand how to implement this function to just display categories. Anyway you can simply paste the code to do this in the comments, or some sort of link to help me understand better?

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว +1

      If you need to display only a list of categories, you can use the wp_list_categories() method of WP
      Check here the documentation and some examples at the bottom: developer.wordpress.org/reference/functions/wp_list_categories/

    • @jaylab1460
      @jaylab1460 7 ปีที่แล้ว

      Thank you, I am looking to print just the categories and keep them in a specific order with the latest post showing. Just like on this lesson. But instead of just showing the latest posts and their respective categories. I wanted to keep the order of categories. Example
      Daily News - Sports - Videos. I need it to stay in that order with the latest post showing.
      Is this the same function that you are referring too?

  • @thisguyIGOTOUNO
    @thisguyIGOTOUNO 9 ปีที่แล้ว +2

    Hey @alessandro, AWESOME tutorials! Huge help!
    I have a 3 part question: How would I go about looping just the thumbnails of the most recent posts? How would I make the images link to their respected posts? And finally, how could I go about making the images responsive?
    Aiming for something similar to this, codepen.io/mLirette/pen/PqQWab
    Thanks!

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว +2

      +Mike Lirette Hi, thanks for following my tutorials.
      For your questions:
      1. You can just retrieve the featured image with the function the_post_thumbnail()
      2. you wrap the image around the link tag, something like this

  • @kresimircosic6158
    @kresimircosic6158 7 ปีที่แล้ว

    I have a project coming up in 7 days, needs to be done, and these videos are helping me a LOT. But it's still a ton of information all at once. Like for example, the confusing part for me was/is when you enabled a template in the comments for page-notitle.php or a specific page-6.php (in my case page-14.php). Those were just different ways of implementing a specific template, when in fact by default everything else goes by index.php, or I'm wrong? It's confusing and clear at the same time, weird. Would like if you answered me since I'm really short on time! :P Or I would like to chat with you somehow via Google or via some other forms, Skype, Discord whatever... :) Liked video as always!

    • @alecaddd
      @alecaddd  7 ปีที่แล้ว

      Correct!
      You could potentially have a theme with just the index.php, because that file handles everything by default.
      If you create a page.php, all your pages will use that.
      If you create a single.php, all your single blog posts will use that.
      If you create an archive.php, all your categories and tags will use that.
      And so on.
      Check this page to know more: developer.wordpress.org/themes/basics/template-hierarchy/

    • @kresimircosic6158
      @kresimircosic6158 7 ปีที่แล้ว

      Thanks man, for confirming this. You are a really humble guy; and I hope you get some power in your life and never usurp it. I love your tutorials and will be probably my main go-to developer to study from. I really wish I lived in a more normal country where I could donate you something (including a baked potato). Maybe soon something changes.
      I need to finish a custom theme (probably using Bootstrap like you did) for a company next Thursday; which in my mind seems impossible considering I'm a beginner into this. I could slam that page in HTML/CSS without a fuss in couple of days, but WP is too powerful and full of features. It's a real endeavour to 'connect' all these things in the backend, so your Dashboard actually functions as it's supposed to function. (for example; I did a navbar for the project and then realized I hard-coded the links instead of it being dynamic and changable in the Dash...)

  • @dhaval2021
    @dhaval2021 8 ปีที่แล้ว +1

    nice tutorial, Earlier I was very scared by WP but you made it easy, My question is if this is 0.001 of WP_QUERY then how many decades it will take to learn whole WP_QUERY ?? just kidding :)

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      ahahaha, well, it took me almost 5 years to learn everything and I still miss something sometimes. But no worries, since I started learning coding a lot of free resources and online classes are available. Way easier and faster now :D

  • @MMAStory
    @MMAStory 6 ปีที่แล้ว +1

    Super Simple

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      Indeed :D

  • @mihajloilic5836
    @mihajloilic5836 2 ปีที่แล้ว

    Awesome!!!

  • @rohitgour2896
    @rohitgour2896 6 ปีที่แล้ว +1

    Thankyou sir

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว

      You're very welcome :D

  • @marcoberardini9728
    @marcoberardini9728 8 ปีที่แล้ว +1

    Thanks for the great tutorials !!
    I wanted to share an issue I had with post_per_page => , I uploaded content to my installation of wordpress and it included sticky post which kept coming up in my Query. To solve the problem code below

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Marco Berardini Thanks for sharing your experience, it'll helpful for others.

  • @eljay9253
    @eljay9253 8 ปีที่แล้ว +1

    Another good tutorial.
    It is getting harder though

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว +4

      +eL Jay That's the point right? Where's the fun if everything is too easy :D

  • @kramlig90
    @kramlig90 9 ปีที่แล้ว +1

    this is very clear tutorial, .thanks for posting like this sir, .^_^

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      +Mark Gil Sumanlad Thank you for following!

    • @kramlig90
      @kramlig90 9 ปีที่แล้ว +1

      Welcome sir, .and also thank you for posting a very knowledgeable tutorial, .^_^

  • @ale.riccardi
    @ale.riccardi 8 ปีที่แล้ว +1

    Video molto utili e facili da capire! Sei italiano vero?

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Alessandro Riccardi si, mi hai beccato 😃

  • @manualvarado2212
    @manualvarado2212 6 ปีที่แล้ว +1

    Hahahahaha, you are using Hipster Ipsum! Now you are even cooler.

    • @alecaddd
      @alecaddd  6 ปีที่แล้ว +1

      It's the best :D

  • @halahabka7145
    @halahabka7145 9 ปีที่แล้ว +1

    Alessandro I love all your tutorials till now but I find that you repeated your self a a lot in this one in the "not use query post" thing :( But anyway thank you because your videos are AWESOME!! :D I am recommending them to all my friends

    • @alecaddd
      @alecaddd  9 ปีที่แล้ว

      Hi, thank you so much for following. I noticed that too, sometimes I get stuck on a topic and I keep repeating myself. I'm still trying to improve the quality of my tutorials. Thanks for your feedback.
      Happy Coding!

  • @zafershoaybi
    @zafershoaybi ปีที่แล้ว

    thanks for you

  • @MarcoEsposito58
    @MarcoEsposito58 8 ปีที่แล้ว +1

    Ciao +Alessandro Castellani ti ringrazio innanzitutto per tutti i meravigliosi video che hai pubblicato e ti chiedo un aiuto riguardo a questo video perché purtroppo non riesco a visualizzare la page-home.php come si vede... non capisco come mai

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      +Marco Esposito Ciao, grazie per il commento positivo. Che problema hai con il file page-home.php?
      Hai seguito passo passo il tutorial? Hai provato ad accedere all repository su GitHub per controllare se il codice che hai scritto è identico al mio?

    • @MarcoEsposito58
      @MarcoEsposito58 8 ปีที่แล้ว +1

      +Alessandro Castellani caspita mi hai già risposto anche se è domenica! Grazie! :) Si alla fine avevo copiato il tuo stesso codice dal repository ma continuavo a non vedere la page-home.php come la tua. Allora mentre ero in gita domenicale con mia moglie mi è venuta l'idea di creare un'altra pagina (page-5.php) e sono riuscito a visualizzare correttamente il tutto. Però se clicco Home... niente... vedo solo il contenuto della home page senza il resto... Spero di non essermi dilungato troppo e grazie ancora per la tua bravura, il tuo spirito di condivisione, la tua pazienza e il tuo prezioso aiuto :)

    • @alecaddd
      @alecaddd  8 ปีที่แล้ว

      Mhhhh, abbastanza strano. Se il file page-home.php non viene associato all tua pagina vuol dire che il permalink è diverso. Controlla nell;admin panel il permalink della tua Home Page, e vide se è effettivamente tuosito.com/home

    • @MarcoEsposito58
      @MarcoEsposito58 8 ปีที่แล้ว +1

      hai ragione!!! Avevo usato la "Pagina di esempio." rinominandola "Home" ma tralasciando lo Slug! Ora funziona! Ti ringrazio ancora e proseguo con i tuoi ottimi video :)

  • @15minutelol50
    @15minutelol50 5 ปีที่แล้ว

    Thks pro!

  • @bradchellingworth5973
    @bradchellingworth5973 5 ปีที่แล้ว

    Great vids and thank you. but if I may just say I found myself watching these on 2x speed, like this video for example takes 10 minutes before you actually get to the query.

  • @latrilha8537
    @latrilha8537 3 ปีที่แล้ว

    For the first time it is not super simple hahaha