[wp-trac] [WordPress Trac] #35892: Small issue in "get_calendar" function

WordPress Trac noreply at wordpress.org
Sat Feb 20 20:55:10 UTC 2016


#35892: Small issue in "get_calendar" function
------------------------------+-----------------------------
 Reporter:  yetAnotherDaniel  |      Owner:
     Type:  defect (bug)      |     Status:  new
 Priority:  normal            |  Milestone:  Awaiting Review
Component:  Widgets           |    Version:  4.4.2
 Severity:  normal            |   Keywords:
  Focuses:                    |
------------------------------+-----------------------------
 In the "get_calendar" function (wp-includes/general-template.php) the
 following wpdb method with a SQL command is called:

 'get_var("SELECT 1'

 This will not work as "get_var" does not support that:
 https://core.trac.wordpress.org/ticket/4090

 The error is tiny. However, this seems to be a common mistake if you
 google for:
 "get_var" "SELECT 1"

 I either suggest to enable this functionality in the "get_var" method or
 fix it in get_calendar function as well as describe the issue in the codex
 (https://codex.wordpress.org/Class_Reference/wpdb#SELECT_a_Variable).

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35892>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list