header

C++ templates declare in .h, define in .hpp

I saw some code in which the developer defined a class template in a .h file, and defined its methods in a .hpp file. This caught me a bit by surprise. Are there are particular conventions in C++ when dealing with templates and what files they should be in? For example say I had a Vector class template with methods for vector operatio...

Header issue, wordpress

Tried to make a change to the address in the header.php, and for some reason it changed only in the index file and not in any of the other pages. Can anyone tell me why this is? In the index page and both other page template options the header is called the same... <?php ?><!DOCTYPE html> <html <?php language_attributes(); ?>> <head> ...

Serial port library/header file in C for WinCE

Hi, I am a newbie in WinCE application programming. But the starting is not as smooth as expected. I could not find code examples, tutorials to learn from. I could not find a book on WinCE programming. Are all the libraries and header files for winCE same as for windows (WIN32)? I am programming in C. I want to use serial port communi...

PHP Header Location Change of Parent Frame

Hi, I have an iFrame that does some background processing. When this processing is complete I would like to re-direct the user to another page, but the header change code is only affecting the embedded iFrame. Is there a way to target the main window? ...

Functions and header files (ansi c)

This is a question from job interview.Let's say we have "a.c" source file with some function and "a.h" as its header file.Also we have main.c file which calls that function.Now let's suppose we have "a.h" and "a.o"(object file) and a.c is unavailable.How do we call this function now? (I had a hint that we need to use function pointers.An...

Where is ERROR_PENDING defined?

The MSDN documentation for CommitTransactionAsync indicates it may produce an ERROR_PENDING error code. However, this error code does not seem to be defined in winerror.h, nor any other header reachable from ktmw32.h or windows.h (using the version of the Windows SDK included in Visual Studio 2010). In fact, I cannot find a single file c...

Header redirect, sessions lost, but only after about 5 minutes

function redirect($url){ header("HTTP/1.1 303 See Other"); header("Location: $url"); exit(); } I have the function called when certain input buttons are clicked. The session is set on every page, and it IS passed if the the button is clicked within 5 minutes. But the session is lost after about 5 minutes if the button is ...

Prototype parameter names

In my header, I have a prototype declaration like this: void move(int, int); I can omit the parameter names, that's how I'm used to it from C. I do that so that I don't have to keep the parameter names in sync - it's extremely confusing if they differ between prototype and implementation. Right now, I'm documenting all of my code wit...

How to keep header from being selected when there is one item in a QTableWidget?

I can't seem to keep the horizontal header from being selected when I select a single row in a QTableWidget. Example: How can I prevent the header from being selected too? This only happens when one row is in the table. If it has more than two rows, then it works as expected and only the row itself is selected. Note: I have set u...

Objective-C pre-compilation error

Hi all, I'm compiling a big iPhone app and am getting 24 of the same error... cc1plus: note: obsolete option -I- used, please use -iquote instead cc1: error: -I- specified twice This error is repeated 24 times for the same prefix header file. Any idea what's going on? Thanks! ...

Where is msleep declared?

The source from here says that it is supposed to work on the iPhone. I have worked with it, but I get 2 errors, saying that msleep() is undeclared. I have tried to include unistd.h, time.h, and numerous others. How can I get this to work? Thanks. ...

Need help getting this auto-download header to show the right path

Hi folks, I have a page with mp3s that are playable from a player, and there are also links to download the songs. When the user clicks on the download link, it needs to open the download dialog instead of opening a media player, so it was recommended to me to use this header script: includes/auto-download.php: <?php $path = $_GET['pa...

I am trying to create an array of objects inside a header file which is failing (Starting C++ Programmer)

EDITED BELOW FOR UPDATES!!! Thank you for the help, please by all means point out ALL mistakes , I don't care if it sounds rude or mean or whatever, emo junk. Just give it to me straight so I can understand what is going wrong. Hi everyone! I am a rookie C++ programmer trying to learn and gain some IRL exp for C++. I am attempting the...

header('location: ..') not working

(1)I'm in the process of uploading my website to a remote web server. (2)The site's template system is set up in a way that all of the pages are formed by sending url-encoded get requests to index.php (3)Loading up the initial page works. This page determines the location of the next page by evaluating the value of its form. (4)The r...

Weird header("Location:"); error

I've done tons of redirects using PHP's header function. This one has stumped me. On my dashboard controller, I check whether or not the $_SESSION['loggedin'] is set. If it's not set, I want to send the user back to the main page. However, I keep getting the "too many redirects" error, even though I only have it set once. Can anyone hel...

header for excel file save as

hello, im able to output an excel file by php and it opens correctly in excel. No problems there. When the user clicsk save as in Excel it comes with first option .txt How can i set the header so first option will .xls with save as. Headers im using now : $filename="jaar.xls"; header("Content-Type: application/vnd.ms-excel"); header("C...

WPF question regarding the binding inside of DataGridTextColumns

Hello, Today I noticed a strange behavior regarding binding the header of a DataGridColumn to the ViewModel. The following binding works perfectly (name of the DataGrid is MyGrid): <DataGridTextColumn Binding="{Binding Name}" Width="*" CanUserReorder="False" CanUserResize="False" IsReadOnly="True"> <Da...

Dock an item on top of UITableView like imdb app on ipad?

Hi, I want to do something similar to the left UITableView on imdb app on ipad. Once you have selected an item, it will become the first item on the top and it will dock there. When you flick the list below, it will always be there. Anyone has any suggestion on how I can achieve that? ...

Can you use a php header redirect on a rtmp url?

Curious, as I've been asked to do this. I can't find any sort of protocol anywhere. ...

PyQt: How to catch mouse-over-event of QTableWidget-headers?

Hi guys, what I want to do is to change the text of a QLable, everytime I hover with the mouse over the horizontalHeaders of my QTableWidget. How can I do that? Everytime I'm over a new header I need a signal and the index of the header. Hope someone of you has an idea. There must be a function, because if you hover over the headers, th...