WordPress.org

Ready to get started?Download WordPress

Forums

custom post_types not showing in query on Localhost (2 posts)

  1. Earthman Web & Media
    Member
    Posted 3 years ago #

    Hi, I have a site that works fine with custom post_types and taxonomies, however when I install it on a Localhost install, the custom post_types are not showing in the wp_query variables.

    Here are my environment variables, could this be the issue?

    External (working) site:
    PHP: 5.2.6
    Configure command:
    './configure' '--prefix=/usr/local/php-5.2.6-1' '--enable-cli' '--enable-cgi' '--enable-fastcgi' '--disable-debug' '--disable-rpath' '--disable-static' '--with-pic' '--with-openssl=/usr' '--enable-bcmath' '--with-bz2' '--enable-calendar' '--enable-ctype' '--with-curl' '--with-db4' '--with-zlib-dir=/usr' '--with-xsl' '--enable-exif' '--enable-ftp' '--with-gd' '--enable-gd-native-ttf' '--with-ttf' '--with-jpeg-dir=/usr' '--with-png-dir=/usr' '--with-freetype-dir=/usr' '--with-gettext' '--with-iconv' '--with-imap' '--with-kerberos=/usr' '--with-imap-ssl=/usr' '--enable-mbstring' '--with-mcrypt' '--with-mhash' '--with-mime-magic=/usr/share/misc/file/magic.mime' '--with-mysql=/usr/bin/mysql_config' '--with-pcre-regex=/usr' '--with-pgsql' '--with-pspell=/usr' '--enable-sockets' '--enable-wddx' '--with-xmlrpc' '--with-zlib=/usr' '--with-pear' '--with-layout=GNU' '--with-ldap' '--with-sqlite' '--with-mysqli=/usr/bin/mysql_config' '--enable-pdo' '--with-pdo-mysql=/usr' '--with-pdo-pgsql=/usr' '--enable-pdo' '--with-pdo-mysql=/usr' '--with-pdo-pgsql=/usr' '--enable-soap'
    Server API:CGI/FastCGI

    WP-query[request]: (note additional post_types)
    [request] => SELECT SQL_CALC_FOUND_ROWS wpeassandbox_posts.* FROM wpeassandbox_posts WHERE 1=1 AND wpeassandbox_posts.ID IN (600, 849, 852, 869, 875, 877, 894, 896, 909, 971, 976, 983, 984, 992, 994, 1001, 1032, 1034, 1091, 1109, 1137, 1183, 1201, 1243, 1244, 1289, 1302, 1312, 1317, 1342, 1343, 1345, 1348, 1363, 1391, 1409, 1419, 1440, 1465, 1477, 1509, 1523, 1542, 1556, 1605, 1685, 1704, 1859, 1907, 1917, 1934, 2078, 2166, 2415, 2418, 2435, 2441, 2443, 2460, 2462, 2475, 2537, 2542, 2549, 2550, 2558, 2560, 2567, 2598, 2600, 2657, 2675, 2703, 2749, 2767, 2809, 2810, 2855, 2868, 2878, 2883, 2908, 2909, 2911, 2914, 2929, 2957, 2975, 2985, 3006, 3031, 3043, 3075, 3089, 3108, 3122, 3171, 3251, 3270, 3425, 3473, 3483, 3500, 3579, 3631, 3684, 3685, 3687, 3757, 3776, 3831, 3832, 3833, 3834, 3848, 3850, 3896, 3998, 4041, 4047, 4229, 4252, 4256, 4257, 4260, 4261, 4333, 4334, 4337, 4341, 4398, 4443, 4445, 4446, 4447, 4448, 4469, 4514, 4810, 4812, 4825, 4826, 4828, 4935, 4943, 4949, 4950, 4956, 4957, 4958, 4959, 5000, 5053, 5106, 5107, 5109, 5179, 5198, 5253, 5254, 5255, 5256, 5270, 5272, 5318, 5420, 5463, 5469, 5651, 5674, 5678, 5679, 5682, 5683, 5755, 5756, 5759, 5763, 5820, 5865, 5867, 5868, 5869, 5870, 5891, 5936, 6232, 6234, 6247, 6248, 6250, 6357, 6365, 6371, 6372, 6378, 6379, 6380, 6381, 6395, 6448, 6501, 6502, 6504, 6574, 6593, 6648, 6649, 6650, 6651, 6665, 6667, 6713, 6815, 6858, 6864, 7046, 7069, 7073, 7074, 7077, 7078, 7150, 7151, 7154, 7158, 7215, 7260, 7262, 7263, 7264, 7265, 7286, 7331, 7627, 7629, 7642, 7643, 7645, 7751, 7759, 7765, 7766, 7772, 7773, 7774, 7775, 7975, 8054, 8060, 8172, 8615, 8625, 8789, 8791, 9097) AND wpeassandbox_posts.post_type IN ('post', 'page', 'attachment', 'training', 'resources', 'jobs', 'articles', 'bod') AND (wpeassandbox_posts.post_status = 'publish' OR wpeassandbox_posts.post_status = 'private') ORDER BY wpeassandbox_posts.post_date DESC LIMIT 0, 10

    Localhost (not working)
    PHP: 5.3.1
    Configure command:
    cscript /nologo configure.js "--enable-snapshot-build"
    Server API: Apache 2.0 Handler
    WP-query[request]: (note missing post_types)

    [request] => SELECT SQL_CALC_FOUND_ROWS wpcsc_posts.* FROM wpcsc_posts WHERE 1=1 AND wpcsc_posts.ID IN (600, 849, 852, 869, 875, 877, 894, 896, 909, 971, 976, 983, 984, 992, 994, 1001, 1032, 1034, 1091, 1109, 1137, 1183, 1201, 1243, 1244, 1289, 1302, 1312, 1317, 1342, 1343, 1345, 1348, 1363, 1391, 1409, 1419, 1440, 1465, 1477, 1509, 1523, 1542, 1556, 1605, 1685, 1704, 1859, 1907, 1917, 1934, 2078, 2166, 2415, 2418, 2435, 2441, 2443, 2460, 2462, 2475, 2537, 2542, 2549, 2550, 2558, 2560, 2567, 2598, 2600, 2657, 2675, 2703, 2749, 2767, 2809, 2810, 2855, 2868, 2878, 2883, 2908, 2909, 2911, 2914, 2929, 2957, 2975, 2985, 3006, 3031, 3043, 3075, 3089, 3108, 3122, 3171, 3251, 3270, 3425, 3473, 3483, 3500, 3579, 3631, 3684, 3685, 3687, 3757, 3776, 3831, 3832, 3833, 3834, 3848, 3850, 3896, 3998, 4041, 4047, 4229, 4252, 4256, 4257, 4260, 4261, 4333, 4334, 4337, 4341, 4398, 4443, 4445, 4446, 4447, 4448, 4469, 4514, 4810, 4812, 4825, 4826, 4828, 4935, 4943, 4949, 4950, 4956, 4957, 4958, 4959, 5000, 5053, 5106, 5107, 5109, 5179, 5198, 5253, 5254, 5255, 5256, 5270, 5272, 5318, 5420, 5463, 5469, 5651, 5674, 5678, 5679, 5682, 5683, 5755, 5756, 5759, 5763, 5820, 5865, 5867, 5868, 5869, 5870, 5891, 5936, 6232, 6234, 6247, 6248, 6250, 6357, 6365, 6371, 6372, 6378, 6379, 6380, 6381, 6395, 6448, 6501, 6502, 6504, 6574, 6593, 6648, 6649, 6650, 6651, 6665, 6667, 6713, 6815, 6858, 6864, 7046, 7069, 7073, 7074, 7077, 7078, 7150, 7151, 7154, 7158, 7215, 7260, 7262, 7263, 7264, 7265, 7286, 7331, 7627, 7629, 7642, 7643, 7645, 7751, 7759, 7765, 7766, 7772, 7773, 7774, 7775, 7975, 8054, 8060, 8172, 8615, 8625, 8789, 8791) AND wpcsc_posts.post_type IN ('post', 'page', 'attachment') AND (wpcsc_posts.post_status = 'publish' OR wpcsc_posts.post_author = 2 AND wpcsc_posts.post_status = 'private') ORDER BY wpcsc_posts.post_date DESC LIMIT 0, 10

  2. Earthman Web & Media
    Member
    Posted 3 years ago #

    Does my question make sense? Any feedback/ideas most appreciated, thanks!

Topic Closed

This topic has been closed to new replies.

About this Topic