include

php includes is there any way to include a file relative only to that document?

If I have an index.php file that includes inc/footer.php I would write: include 'inc/footer.php'; If I want to include another file inside footer.php, I must do it relative to the index.php file (the one that is including it). This may not be a problem, but what about if I want to include index.php from an entire different location? ...

Is there a way of including HTML pages without needing any javascript or server-side code, only HTML

Is there a way of including HTML pages without needing any javascript or server-side code, only HTML. Basically I can't be sure if the server supports server side includes. I don't want to use javascript and I don't want to use any PHP or other server side functionality. Is there any way to do this. At the moment I suspect not, but wou...

Netbeans, jsp:include

I'm using JSF in NetBeans. All I want to do is to include a page within another page. But whatever I tried, and when I run the main page, I get no error but I can't see my included page in a main page. Why? My main page is: <jsp:root version="2.1" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xml...

How to add additional include directory on solution level?

I have a big solution with ~30 projects(it's not my fault). I have several versions of boost. Each solution uses it's own version of boost. For now boost is set for each project(30 times). How to set boost on solution level? I want to say this solution uses boost_1.39, this solution uses boost_1.33. I can add path globally on VisualStu...

Header files in subdirectories (e.g. gtk/gtk.h vs gtk-2.0/gtk/gtk.h)

Hello, I'm trying to build a hello world using GTK, which includes the line: #include <gtk/gtk.h> as you would expect. The Makefile supplied has the line: GTK_INCLUDE = -I/usr/local/include so it would expect to find gtk.h in /usr/local/include/gtk/gtk.h. However on my system, it is located in /usr/local/include/gtk-2.0/gtk/gtk.h...

How can I include the output of a Perl script into a PHP page?

We've been asked to support some rather old Perl forms on a new site, as we're using a PHP based CMS we need to include the Perl scripts into our new CMS. I've tried a bit of shell_exec but that's disabled. Has anyone got any ideas? ...

regex and $_GET

I'm making a little site for a friend, noobfriendly, so she can add pages easy. I think I'm just gonna include everything in index.php. So she can just drop a page in a folder named /pages/ and it's done. index.php if (preg_match('/[a-zA-Z]/', $_GET['page'])){ $page = 'pages/'.$_GET['page'].'.php'; if ($page) { include $page; } else ...

Ruby module with a static method call from includer class

I need to define the constant in the module that use the method from the class that includes this module: module B def self.included(base) class << base CONST = self.find end end end class A def self.find "AAA" end include B end puts A::CONST But the compiler gives the error on the 4th line. Is there any ...

JavaScript: Inline Script with SRC Attribute?

Hi All, I'm used to including and using JS like so: <script type='text/javascript' src='/path/to/script.js'></script> .... <script type='text/javascript'> alert('Do some stuff here, using resources defined in script.js.'); </script> Just out of curiosity, does anyone know the rule for having an inline script with a src attrib, li...

Ruby: a class extending a module

Hi, I'm trying to to define a class called "HTML" to extend Nokogiri - which uses modules. I tried the following: require 'nokogiri' class HTML include Nokogiri end and require 'nokogiri' class HTML extend Nokogiri end but so far it's been impossible that the class HTML inherit of all the functions in nokogiri. So stuf...

How to write the Where clause in my ObjectQuery?

Please see my code: var miportal = new AdventureWorksEntities(); // one to many relationship var result = miportal.AddressType .Include("CustomerAddress") .Where(at => at.CustomerAddress.Any(ca => ca.CustomerID == 3)); there are 2 tables; AddressType and CustomerAddress (1 CustomerAddress has...

conditional include in linq to entities?

I felt like the following should be possible I'm just not sure what approach to take. What I'd like to do is use the include method to shape my results, ie define how far along the object graph to traverse. but... I'd like that traversal to be conditional. something like... dealerships .include( d => d.parts.where(p => p.price < 1...

Any MSVC equivalent to GCC '-include' flag?

In GCC you can use the '-include ' flag to automatically include a file in the compilation unit. Is there any equivalent method for this in MSVC? ...

Subdirectory Rewrite | Include All Relative Stuff

I'm trying to hide actual sub-directory from url path using mod_rewrite. The folder actual name is members and i want users to use area instead. The code I'm using works but no images or relative stuff is loading. The rule is missing certain parameters. Can you point me in the right direction? RewriteEngine on RewriteRule ^area/$ /mem...

How does visual studio know which cpp files to rebuild when an include file is changed?

In some of my VS 2005 projects, when I change an include file some of the cpp files are not rebuilt, even though they have a simple #include line in them. Is this a known bug, or something strange about the projects? Is there any information about how VS works out the dependencies and can I view the files for that? btw I did try some ...

C++ include file browser

I have a very large project with tons of convoluted header files that all include each other. There's also a massive number of third-party libraries that it depends on. I'm trying to straighten out the mess, but I'm having some trouble, since a lot of the time I'll remove one #include directive only to find that the stuff it was includ...

How to force Visual Studio preprocessor case sensitivity with #includes?

If you have a header file named ThisIsAHeaderFile.h, the following will still locate the file in Visual Studio: #include <ThisIsAheaderFile.h> Is there a way to enforce case sensitivity so that the #include will result in an error? ...

Using libraraies

Hi , I have a Library built in Macosx ibopencore-amrnb.a. Can I use it with my Iphone app as library? If yes How ? If not How Do i get the library working with Iphone app? Thanks, Sowri ...

Displaying the #include hierarchy for a C++ file in Visual Studio

Problem: I have a large Visual C++ project that I'm trying to migrate to Visual Studio 2010. It's a huge mix of stuff from various sources and of various ages. I'm getting problems because something is including both winsock.h and winsock2.h. Question: What tools and techniques are there for displaying the #include hierarchy for a Vis...

Maintaining Eclipse project include/lib paths in CVS

Background: Here at the office my group uses a common linux environment where we do our code development. Our code is kept in CVS. The latest releases of our various libraries are kept in a specific directory (ie /data/group_projects/lib). Our Makefiles/Ant builds all specify what libraries are needed. We use autoconf to create the make...