vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   Deluxe vB User login and access control on non vB pages (https://vborg.vbsupport.ru/showthread.php?t=108026)

erinys 02-27-2007 06:35 AM

I'm pretty sure thats basic VB since i dont have a lot of hacks and non of them is password related :)

I'll see if i can find the setting for you.

Btw im getting reports of more members now getting my page down due to the hack / expired passwords, so its pretty serious.

thanks for looking into it.

Dzi13 03-01-2007 07:49 PM

Hello!

I have some problems with charset. My site use windows-1250 and forum use ISO-8859-1. After i install Deluxe vB User login script letters on my site get messed.
If i remove inlusion of global.php letters are OK (but then script doesn't work)

Can someone help me?

erinys 03-05-2007 06:17 AM

any news bill?

Chicago_VLNU_4s 03-10-2007 08:21 AM

hmmm. this worked before I switched servers.. It works and everything but now I get this error above the avatar

Quote:

Warning: getimagesize() [function.getimagesize]: URL file-access is disabled in the server configuration in /home/.mojo/*****/offthaave.com/login_inc.php on line 34

Warning: getimagesize(http://www.offthaave.com/forums//image.php?u=1) [function.getimagesize]: failed to open stream: no suitable wrapper could be found in /home/.mojo/*****/offthaave.com/login_inc.php on line 34
Any ideas?

cmcnabb 03-15-2007 12:04 AM

First - thanks for the awesome hack - this is great and exactly what I need. But I seem to be redirecting to the forum home page on login. I'm using the newest VB, and would really prefer to return to the originating page.

Billspaintball 03-18-2007 11:39 PM

Quote:

Originally Posted by cmcnabb (Post 1203727)
First - thanks for the awesome hack - this is great and exactly what I need. But I seem to be redirecting to the forum home page on login. I'm using the newest VB, and would really prefer to return to the originating page.

It should return to the originating page by default.

What browser are you using?
If its Firefox can you try another browser such as IE and see if it does the same?

erinys 03-19-2007 07:54 AM

Hey bill,

I guess no luck yet figuring out why a site wich uses this mod, turn completely 404 on the pages where this addon is included when someone his password is expired.

This can potentional be very damaging to your site, as everyone in the community most likely is going to have his password expire sooner or later, and when that happends, the website will appear to be completely down :(

If you cant find the problem, i would suggest to everyone to uninstall this addon, because it has the potential of breaking your entire site.

I really hope you can find a solution for this, or at least talk with the DEV as to why this is happening.

thanks!

Billspaintball 03-20-2007 01:58 AM

Quote:

Originally Posted by erinys (Post 1207168)
Hey bill,

I guess no luck yet figuring out why a site wich uses this mod, turn completely 404 on the pages where this addon is included when someone his password is expired.

Ive had a look on my test site but cant find any option that allows me to force passwords to expire.
Without being able to replicate the problem I cant fix it.

erinys 03-21-2007 09:06 AM

Ouch, yes that is a problem

ok i checked in the phpmyadmin, and for the table "users" there is a row wich is called "passworddate" This row has the date it happend for me, and last changed it, so my guess is that if you set that date to a couple years backwards, the forum should set you expired password.

else might wanna check with the guys on vbulletin.com

thanks!

Chicago_VLNU_4s 03-21-2007 10:36 AM

Quote:

Originally Posted by Chicago_VLNU_4s (Post 1200052)
hmmm. this worked before I switched servers.. It works and everything but now I get this error above the avatar



Any ideas?

no help huh?

Billspaintball 03-21-2007 10:48 PM

Quote:

Originally Posted by Chicago_VLNU_4s (Post 1208688)
no help huh?

Its the configuration of your new server.
You will need to speak to your host and get them to fix it, or delete the display avatar section of the code.

Billspaintball 03-21-2007 10:52 PM

Quote:

Originally Posted by erinys (Post 1208644)
Ouch, yes that is a problem

ok i checked in the phpmyadmin, and for the table "users" there is a row wich is called "passworddate" This row has the date it happend for me, and last changed it, so my guess is that if you set that date to a couple years backwards, the forum should set you expired password.

else might wanna check with the guys on vbulletin.com

thanks!

I will have a look with phpMyAdmin at the users table when I get home.
I may be able to replicate it by changing that date and go from there.

erinys 04-01-2007 11:01 AM

Hi bill,

Sorry, i have deactivated this addon for now :( when you buy something in vbplaza and it expires (like a sticky topic) this addon also makes the whole site go 404 :(

Something is up with the way it handles something when it "expires", and when it does it breaks every single page on the site where this module is loaded :(

im running 3.6.4 btw, can that be the problem? this works fine on 3.6.4 right?

RoutineX 04-01-2007 07:18 PM

Hi.

Just a couple of questions:

1) I debugged while running the script, and I can't really see that $session[sessionhash] and $session[sessionurl] is used.

2) I'm not 100% sure how this works when it comes to performance, but when I debugged and looked at the available variables from the global.php there were a huge amount of vars and arrays that isnt needed at all.

Wouldn't it be best to only create objects of the things we really need (i.eg create the db object and get the $vbulletin[userinfo] array). If you i.eg look at $vbulletin['forumcache'] alone, it has over 408 arrays (depending on number of forums you have created) with 25 values each. Other unnecessary things are $header, headinclude, footer, etc etc.

Wouldn't this cause a higher load if this is processed everytime a page is viewed?

3) After doing this, my second DB object won't retrieve info in UTF-8 anymore, even though I have:

mysql_query( "SET NAMES 'utf8'", $myDBobj );

Any tips on how to solve this?

Thanks =)

Billspaintball 04-02-2007 11:49 PM

Quote:

Originally Posted by RoutineX (Post 1217750)
Hi.

Just a couple of questions:

1) I debugged while running the script, and I can't really see that $session[sessionhash] and $session[sessionurl] is used.

You can delete that if you like and it should still work, however vB use that in their code for a reason so I did the same.
Quote:

2) I'm not 100% sure how this works when it comes to performance, but when I debugged and looked at the available variables from the global.php there were a huge amount of vars and arrays that isnt needed at all.

Wouldn't it be best to only create objects of the things we really need (i.eg create the db object and get the $vbulletin[userinfo] array). If you i.eg look at $vbulletin['forumcache'] alone, it has over 408 arrays (depending on number of forums you have created) with 25 values each. Other unnecessary things are $header, headinclude, footer, etc etc.

Wouldn't this cause a higher load if this is processed everytime a page is viewed?
Yes there is a bunch of unnecessary stuff in global but I prefer to use it for several reasons.
1 - Better compatibility with future releases of vB. If vB make some changes to how various things work, chances are scripts will still work if they access those functions via the global.php file.
2 - Allows anyone to easily add any new function thats included in the global file.
3 - There is too much stuff happening behind the scenes in vB, its easy to miss some minor thing that causes problems later (like your UTF-8 one)
4 - More secure. Your not potentially creating any security holes with your own code trying to do back end stuff.
5 - The code in global.php is well tested and optimised.

As for extra server load by using global.php, just consider that vB uses it on every page anyhow so it shouldant make much of a difference on server load.
Quote:

3) After doing this, my second DB object won't retrieve info in UTF-8 anymore, even though I have:

mysql_query( "SET NAMES 'utf8'", $myDBobj );

Any tips on how to solve this?

Thanks =)
Sorry, not sure.

xKillswitchx 04-05-2007 07:01 PM

Hey Bill, is there any other way to output usernames instead of $vbulletin->userinfo['userid']?

Billspaintball 04-10-2007 05:17 AM

Quote:

Originally Posted by xKillswitchx (Post 1220570)
Hey Bill, is there any other way to output usernames instead of $vbulletin->userinfo['userid']?

If you want their username just use
$vbulletin->userinfo['username']

KnicksCity 04-15-2007 09:30 PM

Is there a way to display a default image if the user does not have an avatar? With no avatar, errors are displaying because it can't find the image.

Billspaintball 04-16-2007 02:10 PM

What error do you get?
I just deleted my Avatar to try and replicate the error, but It worked fine in IE7 and Firefox 2.0.0.3

KnicksCity 04-16-2007 10:31 PM

Nevermind, no more error. Must have been something else.

By the way, I'm loving this mod. Good work and thanks! :)

devilsmania 04-19-2007 06:07 AM

hey

i get this error ===================================


Warning: main(): open_basedir restriction in effect. File(/var/www/virtual/devilsmania.com/www/forum/global.php) is not within the allowed path(s): (/var/www/virtual/devilsmania.com/www/www/:/var/www/virtual/devilsmania.com/_data/:/var/www/virtual/devilsmania.com/errors/:/usr/share/php/:/tmp/) in /var/www/virtual/devilsmania.com/www/www/index.php on line 3

Warning: main(/var/www/virtual/devilsmania.com/www/forum/global.php): failed to open stream: Operation not permitted in /var/www/virtual/devilsmania.com/www/www/index.php on line 3

Fatal error: main(): Failed opening required '/var/www/virtual/devilsmania.com/www/forum/global.php' (include_path='.:/usr/share/php:/usr/share/pear') in /var/www/virtual/devilsmania.com/www/www/index.php on line 3
===================================


i have vb 3.6.5

forums :
forum.devilsmania.com

login for non VB page :
www.devilsmania.com


what to do ?
sorry/thanks...

Billspaintball 04-20-2007 12:00 AM

Do step two of the troubleshooting guide to ensure that your using the correct paths.
https://vborg.vbsupport.ru/showpost....49&postcount=2

If the path is fine then try the sample login in step five to rule out anything on your page causing a conflict.

Billspaintball 04-24-2007 01:55 PM

Quote:

Originally Posted by erinys (Post 1217401)
Hi bill,

Sorry, i have deactivated this addon for now :( when you buy something in vbplaza and it expires (like a sticky topic) this addon also makes the whole site go 404 :(

Something is up with the way it handles something when it "expires", and when it does it breaks every single page on the site where this module is loaded :(

im running 3.6.4 btw, can that be the problem? this works fine on 3.6.4 right?

Ok,
I have finally had enougth time to play around with this and find the cause and solution.

Cause - When redirected for expired password you are redirected to the directory that your login script is located in, not your forums root.

Fix - Edit phrase called
Code:

passwordexpired
Your current phrase should be
Code:

Your password is {1} days old, and has therefore expired.<br />
<br />
Please change your password using <a href="profile.php?{2}do=editpassword">this page</a>.

change it to

Code:

Your password is {1} days old, and has therefore expired.<br />
<br />
Please change your password using <a href="../forums/profile.php?{2}do=editpassword">this page</a>.

where ../forums/ is your forums directory.

Ive only tested this for expired passwords, not for expired vbplaza, but I would think you would have to edit the expiring vbplaza phrases in the same manner.

devilsmania 04-24-2007 02:03 PM

ok fixed thanks ;)

Billspaintball 04-24-2007 02:54 PM

Updated
  • Fixed - // in paths bug
  • Fixed - Javascript warning in some browsers
  • Fixed - Tidied up some code
  • Fixed - Avatar display code bug

Download the update from the first post, and see the 2nd post for additional workarounds for the 404 on Expired passwords and cross domain login issues.

CSGCarl 04-29-2007 10:29 PM

I'm kinda lost(which isnt hard hehe) I'm trying to make it so when loged out menu a appears but when loged in menu b appears...

I have used the conditionals in the web page its self is that right? if so I take it you can insert code/image/links etc?

Please could someone clear things up abit here/help me out abit:)

Carl

Billspaintball 04-30-2007 12:22 AM

Quote:

Originally Posted by CSGCarl (Post 1237858)
I have used the conditionals in the web page its self is that right?

Yes thats correct.
Quote:

if so I take it you can insert code/image/links etc?
Correct.

The 2nd post in this thread shows various usage examples on how to do this.
See https://vborg.vbsupport.ru/showpost....49&postcount=2

A brief example that shows one lot of text if your logged in and different text if your not is
PHP Code:

<?php 
If ($vbulletin->userinfo['userid']!=0
    {     
    echo 
"Your logged in so we can display this"
    } else { 
    echo 
"Your not logged in so we display this"
    } 
?>

Naturally you can have links, pics, more text, HTML code inside these echo statements.
Hope this helps. :)

CSGCarl 04-30-2007 10:43 AM

Thanks for clearing that up, I must be doing somthing wrong(probably somthing stupid) as I keep getting errors.

Thanks again,
Carl

CSGCarl 04-30-2007 04:31 PM

Ok I get this error 'Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/*****/public_html/homepage.php on line 928'

Code:

This is the code I put in the website:
If ($vbulletin->userinfo['userid']!=0)
        {       
        echo "<img src="http://www.mysite.com/images/bse_top.png" width="248" height="32">";
        } else {
        echo "Your not logged in so we display this";
        }
?>

Can some one tell me what I'm doing wrong please?

Billspaintball 04-30-2007 08:42 PM

Quote:

Originally Posted by CSGCarl (Post 1238325)
Ok I get this error 'Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/*****/public_html/homepage.php on line 928'

Code:

This is the code I put in the website:
If ($vbulletin->userinfo['userid']!=0)
        {       
        echo "<img src="http://www.mysite.com/images/bse_top.png" width="248" height="32">";
        } else {
        echo "Your not logged in so we display this";
        }
?>

Can some one tell me what I'm doing wrong please?

You need to escape the " in your HTML.
Just put \ in front of the " that are part of the HTML and not your PHP.

Like this
PHP Code:

If ($vbulletin->userinfo['userid']!=0)
    {    
    echo 
"<img src=\"http://www.mysite.com/images/bse_top.png\" width=\"248\" height=\"32\">";
    } else {
    echo 
"Your not logged in so we display this";
    }
?> 


CSGCarl 05-01-2007 05:04 PM

It's me again lol

Thanks for that I did that and worked fine til I tried it on a menu...

When I tried it on menu I got these errors;
Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/---/public_html/homepage.php on line 928

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/---/public_html/homepage.php on line 928

This is the code which I tried:

PHP Code:

<?php
If ($vbulletin->userinfo['userid']!=0)

echo \?<
img src=\\?<td style=\?background-image:url('http://www.battlestationextreme.com/images/homepage09.jpg'); height:40px\?>

                                            <table width=\?181\? border=\?0\? cellspacing=\?0\? cellpadding=\?0\? id=\?table16\?>



                                                    <tr>



                                                        <td width=\?15\?><img src=\?http://www.battlestationextreme.com/images/spacer.gif\? alt=\?\? width=\?15\? height=\?40\?></td>



                                                        <td width=\?166\? class=\?text2\?>

                                                        My BSE</td>



                                                    </tr>



                                                </table></td>



                                        </tr>



                                        <tr>



                                            <td style=\?background-image:url('http://www.battlestationextreme.com/images/homepage10.jpg'); height:29px\?>

                                            <table width=\?100%\? border=\?0\? cellspacing=\?0\? cellpadding=\?0\? id=\?table17\?>



                                                    <tr>



                                                        <td width=\?8%\?><img src=\?http://www.battlestationextreme.com/images/spacer.gif\? alt=\?\? width=\?15\? height=\?29\?></td>



                                                        <td width=\?92%\?>

                                                        <a class=\?link1\? href=\?http://www.battlestationextreme.com/forums/usercp.php\?>

                                                        My Account</a></td>



                                                    </tr>



                                                </table></td>



                                        </tr>



                                        <tr>



                                            <td style=\?background-image:url('http://www.battlestationextreme.com/images/homepage10.jpg'); height:29px\?>

                                            <table width=\?100%\? border=\?0\? cellspacing=\?0\? cellpadding=\?0\? id=\?table18\?>



                                                    <tr>



                                                        <td width=\?8%\?><img src=\?http://www.battlestationextreme.com/images/spacer.gif\? alt=\?\? width=\?15\? height=\?29\?></td>



                                                        <td width=\?92%\?>

                                                        <a class=\?link1\? href=\?http://www.battlestationextreme.com/forums/private.php\?>

                                                        My Messages</a></td>



                                                    </tr>



                                                </table></td>



                                        </tr>



                                        <tr>



                                            <td style=\?background-image:url('http://www.battlestationextreme.com/images/homepage10.jpg'); height:29px\?>

                                            <table width=\?100%\? border=\?0\? cellspacing=\?0\? cellpadding=\?0\? id=\?table19\?>



                                                    <tr>



                                                        <td width=\?8%\?><img src=\?http://www.battlestationextreme.com/images/spacer.gif\? alt=\?\? width=\?15\? height=\?29\?></td>



                                                        <td width=\?92%\?>

                                                        <a class=\?link1\? href=\?http://help.battlestationextreme.com/ticket/index.php?a=add\?>

                                                        New Ticket</a></td>



                                                    </tr>



                                                </table></td>



                                        </tr>



                                        <tr>



                                            <td style=\?background-image:url('http://www.battlestationextreme.com/images/homepage10.jpg'); height:29px\?>

                                            <table width=\?100%\? border=\?0\? cellspacing=\?0\? cellpadding=\?0\? id=\?table20\?>



                                                    <tr>



                                                        <td width=\?8%\?><img src=\?http://www.battlestationextreme.com/images/spacer.gif\? alt=\?\? width=\?15\? height=\?29\?></td>



                                                        <td width=\?92%\?>

                                                        <a class=\?link1\? href=\?http://help.battlestationextreme.com/ticket/ticket.php?track\?>

                                                        View Tickets</a></td>



                                                    </tr>



                                                </table></td>



                                        </tr>



                                        <tr>



                                            <td><img src=\?http://www.battlestationextreme.com/images/homepage11.jpg\? alt=\?\? width=\?181\? height=\?8\?></td>\?;
} else {
echo \?Your not logged in so we display this\?;
}
?>

I'm not much good at this :( but once you tell me the problem I should be sorted:erm:

Carl

Billspaintball 05-01-2007 10:46 PM

Hi Carl.

Looks like you have missed using \ in a few places.

For example near the top you have

PHP Code:


echo &#8221;<img src=”<td style=”background-image:url('http://www.battlestationextreme.com/images/homepage09.jpg'); height:40px”> 

but it should be
PHP Code:

 
echo &#8221;<img src=\”<td style=\”background-image:url(\"http://www.battlestationextreme.com/images/homepage09.jpg\"); height:40px\”> 

Then you have

PHP Code:

 
<table width=&#8221;181” border=”0” cellspacing=”0” cellpadding=”0” id=”table16”> 

but it should be
PHP Code:

 
<table width=\&#8221;181\” border=\”0\” cellspacing=\”0\” cellpadding=\”0\” id=\”table16\”> 

and so on for the rest...

If you dont escape every " that is in your HTML inside the echo statement with \ it will cause a premature end to the echo statement and wont work.

CSGCarl 05-06-2007 12:31 PM

Ok well I have looked and replaced all the " with \" but I still seem to get errors for example:

Warning: Unexpected character in input: '\' (ASCII=92) state=1 in /home/----/public_html/homepage.php on line 1039

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/----/public_html/homepage.php on line 1039

PHP Code:

<?php If ($vbulletin->userinfo["userid"]!=0)
    {    
    echo \&
#8221;<td style=\”background-image:url(\”http://www.battlestationextreme.com/images/homepage09.jpg\”); height:40px\”>

                                            
<table width=\&#8221;181\” border=\”0\” cellspacing=\”0\” cellpadding=\”0\” id=\”table28\”>



                                                    
<tr>



                                                        <
td width=\&#8221;15\”><img src=\”http://www.battlestationextreme.com/images/spacer.gif\” alt=\”\” width=\”15\” height=\”40\”></td>



                                                        
<td width=\&#8221;166\” class=\”text2\”>

                                                        
My BSE</td>



                                                    </
tr>



                                                </
table></td>



                                        </
tr>



                                        <
tr>



                                            <
td style=\&#8221;background-image:url(\”http://www.battlestationextreme.com/images/homepage10.jpg\”); height:29px\”>

                                            
<table width=\&#8221;100%\” border=\”0\” cellspacing=\”0\” cellpadding=\”0\” id=\”table29\”>



                                                    
<tr>



                                                        <
td width=\&#8221;8%\”><img src=\”http://www.battlestationextreme.com/images/spacer.gif\” alt=\”\” width=\”15\” height=\”29\”></td>



                                                        
<td width=\&#8221;92%\”>

                                                        
<class=\&#8221;link1\” href=\”http://www.battlestationextreme.com/forums/usercp.php\”>

                                                        
Register!</a></td>



                                                    </
tr>



                                                </
table></td>



                                        </
tr>



                                        <
tr>



                                            <
td style=\&#8221;background-image:url(\”http://www.battlestationextreme.com/images/homepage10.jpg\”); height:29px\”>

                                            
<table width=\&#8221;100%\” border=\”0\” cellspacing=\”0\” cellpadding=\”0\” id=\”table30\”>



                                                    
<tr>



                                                        <
td width=\&#8221;8%\”><img src=\”http://www.battlestationextreme.com/images/spacer.gif\” alt=\”\” width=\”15\” height=\”29\”></td>



                                                        
<td width=\&#8221;92%\”>

                                                        
<class=\&#8221;link1\” href=\”http://www.battlestationextreme.com/forums/private.php\”>

                                                        
Login</a></td>



                                                    </
tr>



                                                </
table></td>



                                        </
tr>



                                        <
tr>



                                            <
td><img src=\&#8221;http://www.battlestationextreme.com/images/homepage11.jpg\” alt=\”\” width=\”181\” height=\”8\”></td>



                                        
</tr>



                                    </
table>\&#8221;;
    
} else {
    echo \&
#8221;Your not logged in so we display this\”;
    
}
?>



I take it this is right?
PHP Code:

<?php If ($vbulletin->userinfo["userid"]!=0)

Cheers,
Carl

Billspaintball 05-07-2007 01:12 AM

Hi Carl,
I should have been a little clearer.
You need to escape the " that are part of the HTML code, not the " that are part of the PHP code.

Quote:

Originally Posted by CSGCarl (Post 1242426)
Ok well I have looked and replaced all the " with \" but I still seem to get errors for example:

.........

Code:

<?php If ($vbulletin->userinfo["userid"]!=0)
        {       
        echo \”<td style=\”background-image:url(\”http://www.battlestationextreme.com/images/homepage09.jpg\”); height:40px\”>

............................................................                                                                                                                                </table>\”;
        } else {
        echo \”Your not logged in so we display this\”;
        }
?>



Should be

Code:

<?php If ($vbulletin->userinfo["userid"]!=0)
        {       
        echo ”<td style=\”background-image:url(\”http://www.battlestationextreme.com/images/homepage09.jpg\”); height:40px\”>

............................................................                                                                                                                                </table>”;
        } else {
        echo ”Your not logged in so we display this”;
        }
?>

Quote:

I take it this is right?
PHP Code:

<?php If ($vbulletin->userinfo["userid"]!=0)


Yes thats ok, thats part of the PHP code so dont escape them.


Hope that all makes sense

Gooses 05-07-2007 11:56 AM

Wow, I love it! Thank you very much for making this.

TheAlchemist 05-08-2007 10:02 AM

ok......I have saved the following in a test.php file located in my website root (local machine)

Code:

<?php
$curdir = getcwd ();
chdir('c:\inetpub\wwwroot\tradinglab\forums');
require_once('c:\inetpub\wwwroot\tradinglab\forums\global.php');
chdir ($curdir);
?>
<html>
<body>
This is a heading<br />
This is some more stuff <br />
And another line<br />
You get the idea<br />
Just place stuff as you normally would with HTML<br />
I use CSS to style and position on my site fwiw<br />
<br />
How about we put the login box right under here?<br />
<br />
<?php
    require_once('c:\inetpub\wwwroot\tradinglab\login_inc.php');
?>
</body>
</html>

when I run the script this is what I get:

Code:

Notice: Undefined index: REQUEST_URI in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1952

Notice: Undefined index: REQUEST_URI in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1952

Notice: Undefined index: QUERY_STRING in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1971

Notice: Undefined index: QUERY_STRING in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1971

Notice: Undefined index: HTTP_REFERER in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1602



Unable to add cookies, header already sent.
File: c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php
Line: 1952

can someone help me iron this thing out? thanks in advance

Billspaintball 05-08-2007 11:45 AM

Quote:

Originally Posted by TheAlchemist (Post 1243558)

when I run the script this is what I get:

Code:

Notice: Undefined index: REQUEST_URI in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1952

Notice: Undefined index: REQUEST_URI in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1952

Notice: Undefined index: QUERY_STRING in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1971

Notice: Undefined index: QUERY_STRING in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1971

Notice: Undefined index: HTTP_REFERER in c:\inetpub\wwwroot\tradinglab\forums\includes\class_core.php on line 1602


That error is from a vB file that we dont touch. Its called by vB's global.php file (I think).
I would hazard a guess that its something to do with a server setting, or possibly your cookie path setting in your vB control panel.

Quote:

Unable to add cookies, header already sent.
File: c:\inetpub\wwwroot\tradinglab\forums\includes\clas s_core.php
Line: 1952
This error is usually caused by whitespace before
PHP Code:

<?php
$curdir 
getcwd ();
chdir('c:\inetpub\wwwroot\tradinglab\forums');
require_once(
'c:\inetpub\wwwroot\tradinglab\forums\global.php');
chdir ($curdir);
?>

however in this case it could well be caused by your initial problem.

TheAlchemist 05-08-2007 12:53 PM

you are definetly right. I installed Vb on a live server, uploaded your hack and it works like a charm. thank you very much!!!!

CypherSTL 05-15-2007 01:13 PM

First of all, great hack.

I am having one issue though.

Code:

Warning: getimagesize() [function.getimagesize]: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution in /home/ulancom/public_html/modules/login_vB36.php on line 34

Warning: getimagesize(http://www.unreallan.com/forums/image.php?u=1) [function.getimagesize]: failed to open stream: Success in /home/ulancom/public_html/modules/login_vB36.php on line 34

Any ideas why it would be doing this?

CSGCarl 05-15-2007 07:21 PM

Hey,

I'm still having a problem I've fixed other but...

Code:


Code:
Code:

<?php
If ($vbulletin->userinfo['userid']!=0)
        {       
        echo "<td style=\"background-image:url(\'http://www.battlestationextreme.com/images/homepage09.jpg\'); height:40px\">

                                                                                        <table width=\"181\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" id=\"table28\">



                                                                                                        <tr>



                                                                                                                <td width=\"15\"><img src=\"http://www.battlestationextreme.com/images/spacer.gif\" alt=\"\" width=\"15\" height=\"40\"></td>



                                                                                                                <td width=\"166\" class=\"text2\">

                                                                                                                My BSE</td>



                                                                                                        </tr>



                                                                                                </table></td>



                                                                                </tr>



                                                                                <tr>



                                                                                        <td style=\"background-image:url(\'http://www.battlestationextreme.com/images/homepage10.jpg\'); height:29px\">

                                                                                        <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" id=\"table29\">



                                                                                                        <tr>



                                                                                                                <td width=\"8%\"><img src=\"http://www.battlestationextreme.com/images/spacer.gif\" alt=\"\" width=\"15\" height=\"29\"></td>



                                                                                                                <td width=\"92%\">

                                                                                                                <a class=\"link1\" href=\"http://www.battlestationextreme.com/forums/usercp.php\">

                                                                                                                Register!</a></td>



                                                                                                        </tr>



                                                                                                </table></td>



                                                                                </tr>



                                                                                <tr>



                                                                                        <td style=\"background-image:url(\'http://www.battlestationextreme.com/images/homepage10.jpg\'); height:29px\">

                                                                                        <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" id=\"table30\">



                                                                                                        <tr>



                                                                                                                <td width=\"8%\"><img src=\"http://www.battlestationextreme.com/images/spacer.gif\" alt=\"\" width=\"15\" height=\"29\"></td>



                                                                                                                <td width=\"92%\">

                                                                                                                <a class=\"link1\" href=\"http://www.battlestationextreme.com/forums/private.php\">

                                                                                                                Login</a></td>



                                                                                                        </tr>



                                                                                                </table></td>\";
        } else {
        echo "Your not logged in so we display this";
        }
?>

Error:

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/-----/public_html/homepage.php on line 1016

And line 1016 is:


Code:
Code:

echo "Your not logged in so we display this";
I can't see whats wrong there.

If some one could help me out this would be great.


Regards,

Carl


All times are GMT. The time now is 03:02 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.02071 seconds
  • Memory Usage 2,023KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (13)bbcode_code_printable
  • (11)bbcode_php_printable
  • (18)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete