Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

PHP Forum


You are currently viewing our PHP Forum as a guest. Please register to participate.
Login



Freelance Jobs

Reply
Whats wrong with this?
Old 05-11-2005, 02:09 AM Whats wrong with this?
ChancesAre's Avatar
Skilled Talker

Posts: 84
Trades: 0
header("location:video.php" ); doesnt seem to be working whats wrong?
this works on my pc but but when i uploaded it in my site.
This isnt the "headers already sent by" error. It wont go to video.php
even if i put echo "blah blah"; after header("location:video.php" );, "blah blah" will still show.


PHP Code:
        if( isset( $_GET['mod'] ) && $_GET['mod'] == "login" )
        {            
            if( isset( 
$_POST['username'] ) && isset( $_POST['password'] ) && loginGranted$_POST['username'], $_POST['password'] ) )
            {
                
session_destroy();
                
session_register"sid_pass""sid_user" );
                
$sid_user $_POST['username'];
                
$sid_pass md5$_POST['password'] );
                
header("location:video.php" );
            } 

Last edited by ChancesAre; 05-11-2005 at 06:45 AM..
ChancesAre is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 05-11-2005, 02:13 AM
ChancesAre's Avatar
Skilled Talker

Posts: 84
Trades: 0
this is the whole thing

PHP Code:
<?php

    
include_once("mysql_query.php");
    include_once(
"config.php");
    include_once(
"./functions/files.php");
    
    
    if( !( 
$db db_connect$forum_hostname$forum_user$forum_pass ) ) )
        echo 
"unable to Connect to Database!!";
    else{
            
        
session_start();
        
$form_vid split"xxxx" ,fileContent"./functions/forms/video.php" ) );
                
        if( isset( 
$_GET['mod'] ) && $_GET['mod'] == "login" )
        {            
            if( isset( 
$_POST['username'] ) && isset( $_POST['password'] ) && loginGranted$_POST['username'], $_POST['password'] ) )
            {
                
session_destroy();
                
session_register"sid_pass""sid_user" );
                
$sid_user $_POST['username'];
                
$sid_pass md5$_POST['password'] );
                
header("location:video.php" );
            }
            else
                
show_login();
        }
        else
        {
            if( isset( 
$HTTP_SESSION_VARS['sid_user'] ) && $HTTP_SESSION_VARS['sid_pass'] )
            {
                if( 
isAllowed$HTTP_SESSION_VARS['sid_user'], $HTTP_SESSION_VARS['sid_pass'] ) )
                {    
                    
showDownloads();
                }
                else
                    
show_login();
            }
            else
                
show_login();
        }
    }

Last edited by ChancesAre; 05-11-2005 at 06:46 AM..
ChancesAre is offline
Reply With Quote
View Public Profile
 
Old 05-11-2005, 06:59 AM
ChancesAre's Avatar
Skilled Talker

Posts: 84
Trades: 0
my bad LOL.. it the stupid headers already sent error.. i forgot to update my config file which was outputing whitespace.
ChancesAre is offline
Reply With Quote
View Public Profile
 
Old 05-11-2005, 08:24 AM
Novice Talker

Posts: 7
Trades: 0
I like threads that fix themselves
__________________
Kind advice :
Please login or register to view this content. Registration is FREE
Coder-X is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Whats wrong with this?
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.13323 seconds with 12 queries