header

System header files redefining macros: how do I tell gcc to ignore?

I have some Motif code that also uses widgets from the Xmt widget set. It include both "Xm/XmStrDefs.h" and "Xmt/ComboBox.h". However, there are some macros that are defined in both files: // XmStrDefs.h: #define XmNarrowSize "arrowSize" // ComboBox.h: #define XmNarrowSize "arrowSize" These are system header files that I'm not allow ...

ASP.net GridView - Use If-Statement in HeaderText property of BoundField

Can I do something like this: <asp:BoundField DataField="Field1" HeaderText='<% IF(Eval("Field2").ToString().SubString(3,4).Equals("Text3"),"Text1","Text2") %>' SortExpression="Field1" /> With the goal of having the header of Field1 be Text1 when the 4th-7th characters of Field2 = Text3 and Text2 otherwise? I tried it and it jus...

Able to Echo before header()

Hi, Came across something strange while migrating to my new server. I have a script that will redirect users to another web page based on certain conditions. What I was doing, however, is echoing out 'Redirecting...', then using the header() function to actually redirect. Here is how the code looked: if( $condition ) { echo 'Red...

Clarification on usage of "Cache-Control" header

We are trying to improve the page load time of a site. In addition to the few other optimizations, I have added a servlet filter to set "Cache-Control" headers to image files(png,gif,jpg). As expected,the image files are now getting cached at the client end and I could verify the expires time of each file by inspecting the temp folder(IE...

[jquery ajax] NS_ERROR_ILLEGAL_VALUE when setting an authorization header

Hi, I'm currently messing around with google APIS. My code consist of 2 request : One for the authentification (using clientLogin). Another to interact with the service from which i need the data. Actually i'm stuck before executing the second request. I'm trying to set an header value to the token value received from the first request...

C++ Single Header File Structure

I want to speed up the build time of my c++ project, and I am wondering if my current structure may cause unnecessary recompilations. I have *.cc and corresponding *.h files, but all my *.cc files include a single header file which is main.h. In main.h, I include everything necessary and extern global variables and declare the function...

email .. should I be able to do this?

I have a website, example.com hosted at godaddy. I was just messing around with PHP's mail function and uploaded the following to my website at example.com: mail( "[email protected]", "test", "test message", "From: [email protected]" ); Why does this work? I mean, it shouldn't, right? The "From" address domain isn't "@example.com". Ye...

Where should I put third-party libraries?

I contribute to a decent-sized C++ project with a number of dependencies. The problem is, the project contains the source of all of its dependencies (e.g. pcre, zlib, etc.). I want to trim the project down to just what's relevant to the program itself. Is there some relatively standard way to compile these libraries and put them somewher...

expires headers? How do I implement them and what are they?

I am using jquery. I have tried searching how to implement them but it makes no sense to me. It talks about apache and Django and Lighttpd, but I have no idea what those are. I used ySlow on my webpage and it told me I need an expires header.. Apparently it really helps with performance though and that's what I really need. Anyone help...

PHP Is there a better way to protect my pages than using header(location) ???

I am protecting my pages by checking the values of my sessions. Is there a more secure way of protecting my pages other than changing the Header Location if the sessions are not valid??? Am I doing anything right??? I have the following at the top of each page: <?php session_start(); //VERIFY LOGIN $validkey = 'br1ll1an...

Make the header and footer visible in a word document (2003 .doc) through Office Interop Library

I am currently opening a word 2003 .doc file and using the Office Interop to get information out of it. For some reason the program will fail reading information from the header if it is not visible. Has anybody checked to see if the header was visible through this before? How would I go about doing it? From other posts I've found some...

Availability.h No such file or directory

Hello, I am trying to build a pre-written app, on OS X 10.5 with the base SDK set to OS X 10.4. There are a couple of pre-compiled header files which are returning errors on compile, in CFNetwork.h where it is including Availability.h "Availability.h - No such file or directory" I checked the header path and this header is not present...

How to add content to an http request?

Hi, I have the following: $request="HTTP/1.0 200 OK Date: Sat, 04 Sep 2010 00:37:36 GMT Expires: -1 Cache-Control: private, max-age=0 Content-Type: text/html; charset=UTF-8 Server: gws X-XSS-Protection: 1; mode=block X-Cache: MISS from proxy.rstel.net X-Cache-Lookup: MISS from proxy.rstel.net:3128 Via: 1.0 proxy.rstel.net (squid/3.0.ST...

C header causes errors when included in some files but not others

The title pretty much says it all. The precise error message that seems to be the root of it is: util.h:4: error: expected declaration specifiers or ‘...’ before ‘size_t’ The header in question is: #ifndef UTIL_H #define UTIL_H void print_array(void*, int, size_t, void (*)(void*)); extern void print_int(void*); extern void prin...

problem with wrapping jqGrid column headers on IE

Hi I'm using jqGrid in my pages, I modified the ui.jqgrid.css file to wrap the column headers like this: .ui-jqgrid tr.jqgrow td { white-space: normal !important; } .ui-th-column,.ui-jqgrid .ui-jqgrid-htable th.ui-th-column{ white-space:normal; } it works fine in all of the browsers but IE! I tried IE7 and IE8 and the probl...

Cmake: how to force including more than one header

Hi, I try to force including header with CMake(2.8.2) and this first solution: SET_TARGET_PROPERTIES(${MyTarget} PROPERTIES COMPILE_FLAGS "/FI\"${ForcedHeader_A}\"/FI\"${ForcedHeader_B}\"") Somehow CMake ignores (or overwrites) the first compiler flag. This happens only if the two compiler flags are the same as in this case . I ...

What is the format for e-mail headers that display a name rather than the e-mail?

I'm trying to create a php script that will handle a mailing list for me using a mySQL database, and I have most of it in place. Unfortunately, I can't seem to get the headers to work right, and I'm not sure what the problem is. $headers='From: [email protected] \r\n'; $headers.='Reply-To: [email protected]\r\n'; $heade...

UITAbleView hidden header?

How do I make a header for a UITableView that is viewable when the UITableView is pulled down, but it hides when the UITableView is released? (Like the twitter app for iPod) ...

ListView with section header problem

Hi I'm adding section headers for my listView, there are few methods on the web. Since I'm using simpleCursorAdapter to manage my listView, I adopted phil bogle's method. http://thebogles.com/blog/2010/02/section-headers-for-android-listviews/ The error occurred at this part of the code: listAdapter.setViewBinder( new SimpleCursor...

Standard C header for ANSI VT100 escape sequences

Is there a standard C header containing ansi escape sequences for say vt100 ? ...