Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Custom Fields (and I18N)
Is it possible to use the same custom field multiple times in a template? I had thought to use a custom field to help define page specific styles, as well as return the page selected for the JS powered menu (so menu displays 'down button' for current page). The custom field works properly in the first application but then *nothing* returns for subsequent applications on the same page. I've turned debugging on, cookies are enabled.

Code for capital.php is as follows

Code:
<?php if(!defined('IN_GS')){ die('you cannot load this page directly.'); } ?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><?php get_page_title();?></title>
<?php get_header(); ?>
    <link href="<?php get_theme_url(); ?>/styles.css" rel="stylesheet" type="text/css" />
    <link href="<?php get_theme_url(); ?>/styles.css" rel="stylesheet" type="text/css" />
    <!-- include jQuery and imagineMenu plugin -->
<script type="text/javascript" src="<?php get_theme_url();?>/js/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="<?php get_theme_url();?>/js/jquery.imagineMenu-1.1.js"></script>

    <script type="text/javascript" charset="utf-8">
$(function () {
    $('#firstNav').imagineMenu({image: '<?php get_theme_url();?>/img/menu.gif', link_widths: [64, 85, 81, 165, 146, 124, 115], selected:'<?php get_custom_field('pageon');?>'});
});
</script>
</head>

<body>
        <div id="container">
<?php

include('top-menu.inc.php');
include('logo-bar.inc.php');
include('capital-main.inc.php');
include('bottom-menu.inc.php');

get_footer(); ?>
    </body>
    </html>

Code for the capital.inc.php file is as follows
Code:
<div id="subheader">
       <?php get_custom_field('subheader');?>"
       </div>
    <!--Is this code live? Echo Pageon variable-->
<!--<?php get_custom_field('pageon');?>-->

    <div id="main<?php get_custom_field('pageon');?>">
        <div id="<?php get_custom_field('pageon');?>text">
        <img src="/images/<?php get_custom_field('pageon');?>heading.jpg" />
        <?php get_custom_field('blurb');?>
        </div>
        <div id="rtimg"></div></div>
        <div id="bottomtext">
        <?php get_page_content();?>
      </div>

The function 'firstNav' in the main template returns the custom field 'pageon' correctly. In the .inc.php file it is as if the content is not being returned at all and the file not being processed... I do not see the added HTML content. Is there a cacheing functionality that I need to disable or clear?

This is the customfields plugin not the special pages although I may switch (will I need to re-do anything?).

Thanks!

Diana

If you want to see the issue live, sitemail me. I don't want to have the client ever find this thread. ;-)
Reply


Messages In This Thread
Custom Fields (and I18N) - by mvlcek - 2011-03-14, 02:40:21
RE: Custom Fields (and I18N) - by thedoglett - 2012-12-20, 02:24:47
RE: Custom Fields (and I18N) - by mvlcek - 2012-12-21, 01:36:37
RE: Custom Fields (and I18N) - by yojoe - 2012-12-20, 07:27:28
RE: Custom Fields (and I18N) - by thedoglett - 2012-12-20, 22:13:16
RE: Custom Fields (and I18N) - by dianajo - 2013-02-06, 03:48:04
RE: Custom Fields (and I18N) - by mvlcek - 2013-02-06, 03:56:40
RE: Custom Fields (and I18N) - by dianajo - 2013-02-06, 05:27:44
RE: Custom Fields (and I18N) - by dianajo - 2013-02-06, 06:56:59
RE: Custom Fields (and I18N) - by krysttof - 2013-02-24, 20:30:41
RE: Custom Fields (and I18N) - by mvlcek - 2013-02-25, 03:51:34
RE: Custom Fields (and I18N) - by krysttof - 2013-02-25, 03:48:42
RE: Custom Fields (and I18N) - by yck.art - 2013-03-01, 06:01:46
RE: Custom Fields (and I18N) - by Laurynas - 2013-04-01, 07:50:40
RE: Custom Fields (and I18N) - by Oleg06 - 2013-04-12, 03:17:44
RE: Custom Fields (and I18N) - by zintonio - 2013-04-29, 18:43:38
RE: Custom Fields (and I18N) - by mvlcek - 2013-04-29, 19:57:25
RE: Custom Fields (and I18N) - by zintonio - 2013-04-29, 22:13:26
RE: Custom Fields (and I18N) - by mvlcek - 2013-04-30, 02:17:11
RE: Custom Fields (and I18N) - by zintonio - 2013-04-30, 04:45:43
RE: Custom Fields (and I18N) - by kolorguild - 2013-05-12, 01:15:59
RE: Custom Fields (and I18N) - by mvlcek - 2013-05-15, 04:19:03
RE: Custom Fields (and I18N) - by retrofan - 2013-06-13, 22:35:50
RE: Custom Fields (and I18N) - by mvlcek - 2013-06-13, 23:05:32
RE: Custom Fields (and I18N) - by retrofan - 2013-06-13, 23:57:17
RE: Custom Fields (and I18N) - by ds10 - 2013-06-26, 07:13:10
RE: Custom Fields (and I18N) - by mvlcek - 2013-06-26, 16:33:04
RE: Custom Fields (and I18N) - by ds10 - 2013-06-26, 20:08:30
RE: Custom Fields (and I18N) - by ds10 - 2013-06-26, 21:49:36
RE: Custom Fields (and I18N) - by mvlcek - 2013-06-27, 02:10:09
RE: Custom Fields (and I18N) - by ds10 - 2013-06-27, 02:37:33
RE: Custom Fields (and I18N) - by Donuts - 2013-08-13, 19:47:49
RE: Custom Fields (and I18N) - by Donuts - 2013-08-13, 20:31:19
RE: Custom Fields (and I18N) - by Oleg06 - 2013-08-13, 20:13:46
RE: Custom Fields (and I18N) - by RobA - 2013-08-21, 05:06:44
RE: Custom Fields (and I18N) - by Italian David - 2013-08-29, 01:22:41
RE: Custom Fields (and I18N) - by b3n.ji - 2013-08-30, 18:06:44
RE: Custom Fields (and I18N) - by megalaner - 2016-05-11, 17:21:34
RE: Custom Fields (and I18N) - by pow - 2013-10-01, 01:12:07
RE: Custom Fields (and I18N) - by mvlcek - 2013-10-01, 01:24:30
RE: Custom Fields (and I18N) - by azeroth2b - 2015-01-15, 02:56:16
RE: Custom Fields (and I18N) - by notafish - 2013-12-04, 00:22:24
RE: Custom Fields (and I18N) - by pow - 2013-12-04, 01:26:17
RE: Custom Fields (and I18N) - by notafish - 2013-12-04, 02:12:32
RE: Custom Fields (and I18N) - by mvlcek - 2013-12-04, 17:03:19
RE: Custom Fields (and I18N) - by xxdex - 2014-03-12, 09:52:16
RE: Custom Fields (and I18N) - by mvlcek - 2014-03-12, 14:07:41
RE: Custom Fields (and I18N) - by xxdex - 2014-03-14, 02:07:49
RE: Custom Fields (and I18N) - by lukinhasb - 2014-07-12, 07:05:11
RE: Custom Fields (and I18N) - by danielg - 2014-07-15, 08:11:56
RE: Custom Fields (and I18N) - by sal - 2014-08-14, 09:58:32
RE: Custom Fields (and I18N) - by shawn_a - 2015-01-16, 01:16:51
RE: Custom Fields (and I18N) - by Carlos - 2015-01-16, 01:25:58
RE: Custom Fields (and I18N) - by shawn_a - 2015-01-16, 01:29:53
RE: Custom Fields (and I18N) - by Carlos - 2015-01-16, 01:35:59
RE: Custom Fields (and I18N) - by shawn_a - 2015-01-16, 02:09:20
RE: Custom Fields (and I18N) - by smsHH - 2015-03-03, 20:05:15
RE: Custom Fields (and I18N) - by Tyblitz - 2015-04-25, 21:55:20
RE: Custom Fields (and I18N) - by philippe - 2016-02-13, 06:35:36
RE: Custom Fields (and I18N) - by mvlcek - 2016-02-14, 00:51:05
RE: Custom Fields (and I18N) - by philippe - 2016-02-18, 23:15:34
RE: Custom Fields (and I18N) - by vixrealitum - 2016-05-01, 04:05:33
RE: Custom Fields (and I18N) - by smsHH - 2016-07-27, 02:37:05
RE: Custom Fields (and I18N) - by mvlcek - 2016-07-27, 03:31:31
RE: Custom Fields (and I18N) - by smsHH - 2016-07-27, 05:25:56
RE: Custom Fields (and I18N) - by vixrealitum - 2020-01-14, 18:25:48
RE: Custom Fields (and I18N) - by aquarius60 - 2016-05-12, 19:38:02
RE: Custom Fields (and I18N) - by Easp - 2016-06-20, 01:53:13
RE: Custom Fields (and I18N) - by pinguin - 2016-09-06, 07:50:25
RE: Custom Fields (and I18N) - by Carlos - 2016-09-15, 03:02:45
RE: Custom Fields (and I18N) - by lakaroth - 2019-07-16, 21:27:31
RE: Custom Fields (and I18N) - by smsHH - 2019-07-16, 21:45:15
RE: Custom Fields (and I18N) - by lakaroth - 2019-07-16, 22:27:46
RE: Custom Fields (and I18N) - by Felix - 2019-07-17, 09:02:54
RE: Custom Fields (and I18N) - by vixrealitum - 2020-11-06, 09:17:27
RE: Custom Fields (and I18N) - by Felix - 2020-11-06, 17:05:53
RE: Custom Fields (and I18N) - by Oleg06 - 2020-11-06, 18:39:33
RE: Custom Fields (and I18N) - by vixrealitum - 2020-11-06, 19:19:06
RE: Custom Fields (and I18N) - by Oleg06 - 2020-11-06, 20:02:31
RE: Custom Fields (and I18N) - by Oleg06 - 2020-11-06, 20:15:08
RE: Custom Fields (and I18N) - by vixrealitum - 2020-11-08, 23:59:28
RE: Custom Fields (and I18N) - by Felix - 2020-11-09, 00:25:18
RE: Custom Fields (and I18N) - by vixrealitum - 2020-11-09, 08:46:53
RE: Custom Fields (and I18N) - by Oleg06 - 2020-12-28, 22:47:18
RE: Custom Fields (and I18N) - by roisag - 2022-05-16, 02:44:24
RE: Custom Fields (and I18N) - by Oleg06 - 2022-12-15, 19:17:40
RE: Custom Fields (and I18N) - by islander - 2022-12-16, 06:23:36
RE: Custom Fields (and I18N) - by tuxy - 2023-02-01, 06:20:24
RE: Custom Fields (and I18N) - by tuxy - 2023-02-01, 06:32:20
RE: Custom Fields (and I18N) - by Carlos - 2023-02-01, 23:48:33
RE: Custom Fields (and I18N) - by mvlcek - 2023-02-02, 02:43:47
RE: Custom Fields (and I18N) - by tuxy - 2023-02-02, 06:37:31
RE: Custom Fields (and I18N) - by islander - 2023-02-02, 06:44:39
RE: Custom Fields (and I18N) - by tuxy - 2023-02-03, 00:11:57
Custom Fields (and I18N) - by polyfragmented - 2011-03-16, 06:11:20
Custom Fields (and I18N) - by mvlcek - 2011-03-16, 06:28:32
Custom Fields (and I18N) - by polyfragmented - 2011-03-16, 06:47:38
Custom Fields (and I18N) - by mvlcek - 2011-03-16, 06:59:09
Custom Fields (and I18N) - by polyfragmented - 2011-03-16, 07:16:20
Custom Fields (and I18N) - by linden - 2011-03-16, 19:13:07
Custom Fields (and I18N) - by mvlcek - 2011-03-16, 19:34:56
Custom Fields (and I18N) - by linden - 2011-03-16, 19:41:57
Custom Fields (and I18N) - by polyfragmented - 2011-03-16, 22:42:44
Custom Fields (and I18N) - by polyfragmented - 2011-03-17, 20:04:11
Custom Fields (and I18N) - by mvlcek - 2011-03-17, 20:24:05
Custom Fields (and I18N) - by polyfragmented - 2011-03-17, 20:43:29
Custom Fields (and I18N) - by yojoe - 2011-03-23, 02:27:03
Custom Fields (and I18N) - by mvlcek - 2011-03-26, 07:00:03
Custom Fields (and I18N) - by mvlcek - 2011-04-01, 03:11:11
Custom Fields (and I18N) - by polyfragmented - 2011-04-01, 21:26:54
Custom Fields (and I18N) - by mvlcek - 2011-04-02, 00:46:03
Custom Fields (and I18N) - by linden - 2011-04-04, 23:05:02
Custom Fields (and I18N) - by ragou - 2011-04-07, 13:25:12
Custom Fields (and I18N) - by mvlcek - 2011-04-07, 20:52:16
Custom Fields (and I18N) - by polyfragmented - 2011-04-09, 00:15:02
Custom Fields (and I18N) - by mvlcek - 2011-04-09, 19:51:06
Custom Fields (and I18N) - by linden - 2011-04-09, 21:05:01
Custom Fields (and I18N) - by Angryboy - 2011-04-10, 16:58:18
Custom Fields (and I18N) - by mvlcek - 2011-04-10, 17:28:40
Custom Fields (and I18N) - by Angryboy - 2011-04-10, 17:43:48
Custom Fields (and I18N) - by jonnboy44 - 2011-04-15, 08:27:23
Custom Fields (and I18N) - by mvlcek - 2011-04-15, 15:46:17
Custom Fields (and I18N) - by jonnboy44 - 2011-04-18, 10:57:20
Custom Fields (and I18N) - by tommy - 2011-04-24, 01:17:21
Custom Fields (and I18N) - by mvlcek - 2011-04-24, 01:42:41
Custom Fields (and I18N) - by tommy - 2011-04-24, 02:02:23
Custom Fields (and I18N) - by mvlcek - 2011-05-08, 19:45:36
Custom Fields (and I18N) - by Oleg06 - 2011-05-09, 04:53:09
Custom Fields (and I18N) - by sal - 2011-05-11, 14:09:03
Custom Fields (and I18N) - by Oleg06 - 2011-06-12, 06:00:07
Custom Fields (and I18N) - by Carlos - 2011-06-12, 06:22:13
Custom Fields (and I18N) - by Oleg06 - 2011-06-13, 01:15:16
Custom Fields (and I18N) - by Carlos - 2011-06-13, 05:52:49
Custom Fields (and I18N) - by Oleg06 - 2011-06-13, 15:03:58
Custom Fields (and I18N) - by mvlcek - 2011-06-18, 00:44:00
Custom Fields (and I18N) - by cyklades - 2011-06-24, 17:41:30
Custom Fields (and I18N) - by mvlcek - 2011-06-24, 17:49:34
Custom Fields (and I18N) - by cyklades - 2011-06-24, 18:13:01
Custom Fields (and I18N) - by Master - 2011-06-25, 16:10:58
Custom Fields (and I18N) - by andyash - 2011-06-26, 01:01:22
Custom Fields (and I18N) - by mvlcek - 2011-06-26, 02:38:44
Custom Fields (and I18N) - by Master - 2011-06-26, 19:05:57
Custom Fields (and I18N) - by mvlcek - 2011-06-26, 19:18:33
Custom Fields (and I18N) - by andyash - 2011-06-26, 19:54:22
Custom Fields (and I18N) - by mvlcek - 2011-06-26, 20:37:36
Custom Fields (and I18N) - by polyfragmented - 2011-06-27, 23:01:32
Custom Fields (and I18N) - by mvlcek - 2011-06-28, 01:09:52
Custom Fields (and I18N) - by cyklades - 2011-07-04, 20:39:19
Custom Fields (and I18N) - by mvlcek - 2011-07-04, 20:50:24
Custom Fields (and I18N) - by cyklades - 2011-07-04, 21:14:09
Custom Fields (and I18N) - by Cerulean - 2011-07-09, 12:53:14
Custom Fields (and I18N) - by mvlcek - 2011-07-09, 15:23:20
Custom Fields (and I18N) - by Cerulean - 2011-07-09, 23:10:49
Custom Fields (and I18N) - by mvlcek - 2011-07-09, 23:15:40
Custom Fields (and I18N) - by Cerulean - 2011-07-09, 23:25:48
Custom Fields (and I18N) - by mvlcek - 2011-07-09, 23:30:17
Custom Fields (and I18N) - by Cerulean - 2011-07-09, 23:41:30
Custom Fields (and I18N) - by yojoe - 2011-07-10, 04:21:08
Custom Fields (and I18N) - by Cerulean - 2011-07-10, 12:20:23
Custom Fields (and I18N) - by mvlcek - 2011-07-10, 15:39:36
Custom Fields (and I18N) - by Cerulean - 2011-07-10, 18:17:02
Custom Fields (and I18N) - by mvlcek - 2011-07-10, 18:35:51
Custom Fields (and I18N) - by Cerulean - 2011-07-10, 19:12:47
Custom Fields (and I18N) - by ronatgetsimple - 2011-07-17, 19:21:22
Custom Fields (and I18N) - by Connie - 2011-07-17, 19:35:06
Custom Fields (and I18N) - by ronatgetsimple - 2011-07-17, 19:47:42
Custom Fields (and I18N) - by ronatgetsimple - 2011-07-17, 20:15:06
Custom Fields (and I18N) - by Connie - 2011-07-17, 20:30:16
Custom Fields (and I18N) - by ronatgetsimple - 2011-07-17, 20:32:22
Custom Fields (and I18N) - by Connie - 2011-07-17, 20:37:04
Custom Fields (and I18N) - by yojoe - 2011-07-24, 04:33:51
Custom Fields (and I18N) - by polyfragmented - 2011-07-27, 05:47:37
Custom Fields (and I18N) - by mvlcek - 2011-08-07, 23:49:12
Custom Fields (and I18N) - by mvlcek - 2011-09-03, 23:44:18
Custom Fields (and I18N) - by filupn - 2011-10-12, 02:51:12
Custom Fields (and I18N) - by mvlcek - 2011-10-12, 03:09:56
Custom Fields (and I18N) - by filupn - 2011-10-12, 03:14:09
Custom Fields (and I18N) - by peter - 2011-10-18, 00:29:39
Custom Fields (and I18N) - by Connie - 2011-10-18, 05:27:11
Custom Fields (and I18N) - by peter - 2011-10-24, 05:58:28
Custom Fields (and I18N) - by arde - 2011-11-03, 00:02:38
Custom Fields (and I18N) - by mvlcek - 2011-11-03, 00:46:41
Custom Fields (and I18N) - by arde - 2011-11-03, 04:50:08
Custom Fields (and I18N) - by graphiclunch - 2011-11-12, 00:43:50
Custom Fields (and I18N) - by tomkop - 2011-11-14, 20:22:07
Custom Fields (and I18N) - by patriotmedia - 2011-11-15, 11:58:03
Custom Fields (and I18N) - by macu - 2011-12-29, 23:59:17
Custom Fields (and I18N) - by Carlos - 2011-12-30, 01:45:58
Custom Fields (and I18N) - by leenm - 2012-02-04, 23:36:01
Custom Fields (and I18N) - by Carlos - 2012-02-06, 04:19:13
Custom Fields (and I18N) - by mvlcek - 2012-02-19, 03:46:04
Custom Fields (and I18N) - by fboender - 2012-02-22, 05:29:41
Custom Fields (and I18N) - by ChriS - 2012-02-24, 00:32:59
Custom Fields (and I18N) - by mvlcek - 2012-02-24, 01:16:26
Custom Fields (and I18N) - by ChriS - 2012-02-25, 08:14:43
Custom Fields (and I18N) - by schizoid - 2012-03-20, 02:18:08
Custom Fields (and I18N) - by mvlcek - 2012-03-20, 03:08:32
Custom Fields (and I18N) - by Nobody - 2012-03-28, 06:12:01
Custom Fields (and I18N) - by yojoe - 2012-03-29, 08:10:32
Custom Fields (and I18N) - by Nobody - 2012-03-29, 09:40:45
Custom Fields (and I18N) - by mvlcek - 2012-03-29, 16:04:19
Custom Fields (and I18N) - by theNo - 2012-04-10, 19:34:46
Custom Fields (and I18N) - by mvlcek - 2012-04-10, 19:49:44
Custom Fields (and I18N) - by theNo - 2012-04-10, 20:34:45
Custom Fields (and I18N) - by mvlcek - 2012-04-10, 20:48:43
Custom Fields (and I18N) - by theNo - 2012-04-10, 21:39:59
Custom Fields (and I18N) - by andyash - 2012-04-19, 16:22:01
Custom Fields (and I18N) - by mvlcek - 2012-04-19, 17:03:14
Custom Fields (and I18N) - by Nobody - 2012-04-20, 00:47:39
Custom Fields (and I18N) - by Angryboy - 2012-04-20, 01:29:15
Custom Fields (and I18N) - by mvlcek - 2012-04-20, 04:03:57
Custom Fields (and I18N) - by Angryboy - 2012-04-20, 04:21:14
Custom Fields (and I18N) - by mvlcek - 2012-04-20, 04:32:51
Custom Fields (and I18N) - by andyash - 2012-04-20, 14:15:35
RE: Custom Fields (and I18N) - by davetest - 2013-02-20, 03:08:39
RE: Custom Fields (and I18N) - by leestwise - 2023-06-20, 03:07:43
Custom Fields (and I18N) - by andyash - 2012-04-25, 03:11:57
Custom Fields (and I18N) - by Draxeiro - 2012-04-25, 07:01:35
Custom Fields (and I18N) - by yojoe - 2012-04-25, 07:08:19
Custom Fields (and I18N) - by Draxeiro - 2012-04-25, 16:48:22
Custom Fields (and I18N) - by mvlcek - 2012-04-25, 17:34:14
Custom Fields (and I18N) - by richard2233 - 2012-04-26, 02:09:25
Custom Fields (and I18N) - by mvlcek - 2012-04-26, 02:28:04
Custom Fields (and I18N) - by Cerulean - 2012-04-27, 20:11:43
Custom Fields (and I18N) - by joene - 2012-05-08, 03:01:44
Custom Fields (and I18N) - by andyash - 2012-05-10, 05:12:21
Custom Fields (and I18N) - by jeroendekker - 2012-05-15, 02:06:24
Custom Fields (and I18N) - by Draxeiro - 2012-05-15, 02:45:50
Custom Fields (and I18N) - by alienee2 - 2012-05-15, 02:46:00
Custom Fields (and I18N) - by jeroendekker - 2012-05-15, 04:29:17
Custom Fields (and I18N) - by mvlcek - 2012-05-15, 04:55:44
Custom Fields (and I18N) - by jeroendekker - 2012-05-15, 05:14:28
Custom Fields (and I18N) - by tommy - 2012-05-31, 22:35:14
Custom Fields (and I18N) - by andyash - 2012-06-10, 17:58:33
Custom Fields (and I18N) - by sal - 2012-06-10, 20:59:41
Custom Fields (and I18N) - by andyash - 2012-06-12, 03:45:01
Custom Fields (and I18N) - by mvlcek - 2012-06-12, 03:54:30
Custom Fields (and I18N) - by andyash - 2012-06-12, 16:20:07
Custom Fields (and I18N) - by cle_hamburg - 2012-06-13, 00:27:52
Custom Fields (and I18N) - by mvlcek - 2012-06-16, 06:23:34
Custom Fields (and I18N) - by andyash - 2012-06-17, 04:08:35
Custom Fields (and I18N) - by mvlcek - 2012-09-30, 15:37:53
Custom Fields (and I18N) - by mrchristoph - 2012-10-26, 15:40:30



Users browsing this thread: 1 Guest(s)