The include tag has no wiki summary.
0
votes
1answer
185 views
How do I call an external php non WordPress class into functions.php?
All my WordPress files are in:
/httpdocs/news/
and the classes I want to call are in:
/private/classes/
Would I use the include_once() function or is there a WordPress function? And how would I ...
0
votes
1answer
582 views
How to check if txt file exists inside template folder?
I have a folder inside my theme where I hold some txt files which I am including in a theme. The problem is that before including txt file I need to check if it does exist. I fail checking it the ...
0
votes
0answers
20 views
Insert blog template on home template
i need to include "blog_page_2_column.php" into homepage.
I insert this into homepage template:
<?php include(TEMPLATEPATH . '/blog_page_2_column.php');?>
Works fine but i cant change the ...
0
votes
0answers
11 views
I need to include post template into home template
i need to include "blog_page_2_column.php" into homepage.
I do this, insert this
into homepage template, works fine but i cant change the page of blog...
Any idea?
The web is ucrburna2013.com.ar
Thx
0
votes
0answers
42 views
shortcode with external file is showing twice [closed]
I have problem on short code activation in my custom plugin. The included file it's shows up twice.
class Configurator{
public function __construct()
{
add_action( ...
0
votes
1answer
73 views
Custom metabox not working
Morning!
I have a call in my functions.php file to include a custom meta-box php file in my theme's directory called: /metaboxes/home-meta.php
The code is as follows for the call:
add_action( ...
0
votes
1answer
51 views
post content includes and seo vs. duplicate content
Trying to find the answer here but can't seem to locate this specific scenario...
We have products that include multiple, defined resources - for example, each has 3 distinct user guides for ...
0
votes
1answer
75 views
Add page as static html into another page
Is there a way to include a wordpress Page into another one? I'm not just talking about getting the content using get_page(), but to import the whole page (theme + content). I have been looking around ...
0
votes
1answer
20 views
Wordpress blog set up
I plan to launch my website with multiple blogs plugged into it, with a main index page for all posts.
I currently have the index running from the root and two blogs running within their own folders ...
0
votes
1answer
57 views
want to include ad code after related post
i want to include ads html code after related post plugin. my site http://www.dewdropzone.com my single php code below
\
<?php ...
0
votes
1answer
81 views
Custom meta box includes
I am having some problems including files for my custom meta boxes. I have a structure like so:
post-meta.php
cmb
teaser_meta_box
load.php
initiate.php
display.php
save.php
So ...
0
votes
2answers
70 views
Including a PHP file via a function that is part of a plugin?
I struggled with this all day, and now am here...
I have a contact form generated by including a php. Presently, I have this code in my theme's index.php to include it:
if ( is_page('contact') ) {
...
0
votes
1answer
58 views
How to include a plugin's php file to another plugin functions file
I need to customize the output of the shortcode of plugin A by using a function of plugin B. So I alter the shortcode function of plugin A by inserting a condition to check the value of the function ...
0
votes
1answer
49 views
Dynamically determine URI to scripts and styles included with a class which could be added from plugin/theme/child theme/mu plugin
I'm working on a settings API class which I'd like to be able to drop into a plugin, wpmu plugin, theme, or child theme directory, and have it just work. My issue is that I'm having trouble figuring ...
0
votes
1answer
95 views
Using includes in Admin options page? [closed]
I am working on a plugin and have a problem with my options page that I can't seem to figure out. The options page works just fine, it is setup in my main plugin file like this:
...
0
votes
1answer
41 views
what is the best way to put data plots into wordpress.com [closed]
I use a wordpress.com blog as diary for scientific research.
I'm looking for a best way to paste data plots into the blog.
Currently I create png images. But I'm wondering if there is a way to ...
0
votes
1answer
58 views
DOCUMENT_ROOT from custom script inside theme [closed]
I am having problems getting document from a custom script inside the theme. It simple not including the domain part.
Here is the current way I am using:
$root = realpath($_SERVER["DOCUMENT_ROOT"]);
...
0
votes
1answer
300 views
can't access some worpress function from my plugin
I'm trying to write a relatively simple plugin. I have two php files, one is included within the other like this:
define( 'PLUGIN_DIR', dirname(__FILE__).'/' );
include_once(PLUGIN_DIR . ...
0
votes
1answer
209 views
What's the best way to include php code in to pages?
I'm currently creating a bunch of (empty) pages and performing conditionals such as is_page('Blabla') on it, which increases my page.php significantly. I'm already using require_once for different ...
0
votes
1answer
128 views
strange parse error when including a loop template within another template
I have a loop template called loop-event-details.php where I have code to display each event.
My main page template is called events-page.php. I use the following code to include the loop template:
...
-1
votes
1answer
166 views
Adding a wp_head hook from an included PHP file
I am using a WordPress plugin for including PHP code within posts and pages, and it's working great - however, I need to insert some styles and scripts, and in order to do that, I need to add a hook ...
-1
votes
1answer
45 views
It is posible to include echo output value? [closed]
I try to show header.php file with include(). In theme administration, I made it 2 options: header.php and headerbreak.php. Using shortcodes like $he_header, I try to include($value) like this:
...
-1
votes
1answer
41 views
Incorporate a php snippet in an include snippet [closed]
I'm not very apt at PHP so please forgive my question which I imagine is child's play to most of you.
I want to incorporate this snippet;
global $post; echo $post->post_name;
Into this line of ...
-2
votes
3answers
41 views
Shortcode return is printing a 1 afterward
function build_total_search_method( $atts ) {
$shorcode_php_function = include( dirname(__FILE__) . "/includes/total_search.php" );
return $shorcode_php_function;
}
add_shortcode( ...
-2
votes
1answer
203 views
How to define category ID in an array?
I have the following:
<?php if ( array( 'is_category', 'is_tag' ) ) { ?>
What I want to do is (that doesn't quite work):
<?php if ( array( 'is_category('13')', 'is_tag' ) ) { ?>
So ...