vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.0 Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=33)
-   -   LinkMe Hack (https://vborg.vbsupport.ru/showthread.php?t=64615)

StarBuG 05-09-2004 05:37 PM

Thx for this nice hack.

I have a question wich is not directly regarding your hack but maybe someone can help me anyway.

I have a hack wich shows "unknown location" in user online and I tried to edit functions_online.php

The second option is clear but how is the the first "case" determant?

case 'LinkMe': (the LinkMe)

It cant be define('THIS_SCRIPT','....'); cause you have "chat" entered in the LinkMe.php (should be fixed ;))

I realy can?t figure that out.

Can anyone help?

StarBuG

Pseudomizer 05-09-2004 06:10 PM

Quote:

Originally Posted by iKwak
Just what I needed! Thanks mate. Clicked Install.

edit: On the source code (inside the textbox), how can we change the HTML format?

Code:

        <!-- http://www.calpolyonline.com/forums Advertising Start -->

        <A HREF="http://www.calpolyonline.com/forums">
<IMG SRC="http://www.calpolyonline.com/forums/images/banners/calpolyonlinemain.gif"></A>

        <!-- http://www.calpolyonline.com/forums Advertising End -->


I want to change the above code to:

Code:

        <a href="http://www.calpolyonline.com/forums/">
<img src="http://www.calpolyonline.com/forums/images/banners/calpolyonlinemain.gif" alt="ALT"></a>


Notice the change? I have removed the <!-- --> brackets, removed capitalization, added a backward slash on the URL and added a "ALT" code. How would you be able to do that? Thank you for the support. Just the hack I was waiting for. :up:

Hi iKwak,

you talk about this section in the php file:

PHP Code:

        <code style=\"white-space:nowrap\">
        &lt;!-- 
$vboptions[bburl] Advertising Start --&gt;<BR>
        &lt;A HREF=\"
$vboptions[bburl]\"&gt;<BR>&lt;IMG SRC=\"$vboptions[bburl]/images/banners/".$file."\"&gt;&lt;/A&gt;<BR>
        &lt;!-- 
$vboptions[bburl] Advertising End --&gt;
        </code></pre> 

Change it for your particular request to:

PHP Code:

        <code style=\"white-space:nowrap\">
                &lt;A HREF=\"
$vboptions[bburl]/\"&gt;<BR>&lt;IMG SRC=\"$vboptions[bburl]/images/banners/".$file."\" alt=\"ALT\"&gt;&lt;/A&gt;<BR>
        </code></pre> 

Cheers,

Pseudomizer 05-09-2004 06:16 PM

Quote:

Originally Posted by StarBuG
Thx for this nice hack.

I have a question wich is not directly regarding your hack but maybe someone can help me anyway.

I have a hack wich shows "unknown location" in user online and I tried to edit functions_online.php

The second option is clear but how is the the first "case" determant?

case 'LinkMe': (the LinkMe)

It cant be define('THIS_SCRIPT','....'); cause you have "chat" entered in the LinkMe.php (should be fixed ;))

I realy can?t figure that out.

Can anyone help?

StarBuG

Thanks StarBug for pointing this out. But regardless of this it should work with the appropriate changes.

But ok. With the next update i will change the header in the PHP file from:

PHP Code:

   define('THIS_SCRIPT','chat'); 

to

PHP Code:

   define('THIS_SCRIPT','LinkMe'); 

And for your first request:

It is very easy to define unknown locations. You have to create 2 entries. One entry like this:

PHP Code:


        
case 'LinkMe':
            
$userinfo['action'] = 'LinkMe';
            
$userinfo['where'] = "<a href=\"LinkMe.php\">$vboptions[bbtitle] LinkMe</a>";
            break; 

and then a second entry like this:

PHP Code:



    
case 'LinkMe.php':
        
$userinfo['activity'] = 'LinkMe';
        break; 

And if you would like to know where to place these please look into my install.html from this hack. This should help.

Cheers,

StarBuG 05-09-2004 06:22 PM

Quote:

Originally Posted by Pseudomizer
Thanks StarBug for pointing this out. But regardless of this it should work with the appropriate changes.

But ok. With the next update i will change the header in the PHP file from:

PHP Code:

   define('THIS_SCRIPT','chat'); 

to

PHP Code:

   define('THIS_SCRIPT','LinkMe'); 

And for your first request:

It is very easy to define unknown locations. You have to create 2 entries. One entry like this:

PHP Code:


        
case 'LinkMe':
            
$userinfo['action'] = 'LinkMe';
            
$userinfo['where'] = "<a href=\"LinkMe.php\">$vboptions[bbtitle] LinkMe</a>";
            break; 

and then a second entry like this:

PHP Code:



    
case 'LinkMe.php':
        
$userinfo['activity'] = 'LinkMe';
        break; 

And if you would like to know where to place these please look into my install.html from this hack. This should help.

Cheers,

You missunderstood me.

I know where I should place this but I need to know where:

case 'LinkMe':

the 'LinkMe' is taken from.

Hope you know what I mean

Ah and one more thing to fixe:

In LinkMe.php

find:
PHP Code:

eval('$navbar = "' fetch_template('navbar') . '";');
eval(
'print_output("' fetch_template('LinkMe') . '");'); 

above it add:
PHP Code:

$navbits = array('' => "LinkMe");
$navbits construct_navbits($navbits); 

;)


StarBuG

Pseudomizer 05-09-2004 06:59 PM

Quote:

Originally Posted by StarBuG
You missunderstood me.

I know where I should place this but I need to know where:

case 'LinkMe':

the 'LinkMe' is taken from.

Hope you know what I mean

Ah and one more thing to fixe:

In LinkMe.php

find:
PHP Code:

eval('$navbar = "' fetch_template('navbar') . '";');
eval(
'print_output("' fetch_template('LinkMe') . '");'); 

above it add:
PHP Code:

$navbits = array('' => "LinkMe");
$navbits construct_navbits($navbits); 

;)


StarBuG


Hi,

the location is the key. In this line you define what should happen:

PHP Code:

$userinfo['where'] = "<a href=\"YOUR.php\ 

If the user is on this php file you define the action.

And thanks for the hint ( it is not a fix ) but it works as it is. Or it doesn't ?

Cheers,

StarBuG 05-09-2004 07:15 PM

I have tried that

the file is called: vb_jukebox.php

i have in functions_online.php

case 'Jukebox':
$userinfo['action'] = 'vB Jukebox';
$userinfo['where'] = "<a href=\"vb_jukebox.php\">$vboptions[bbtitle] vB Jukebox</a>";
break;

case 'vb_jukebox.php':
$userinfo['activity'] = 'vB Jukebox';
break;


But it still shows unknown location
(I added it below your LinkMe code)

Any idea?

And without my "fix" you don?t have a location in the navbar ;)

Greetings

StarBuG

Pseudomizer 05-09-2004 07:20 PM

Quote:

Originally Posted by StarBuG
I have tried that

the file is called: vb_jukebox.php

i have in functions_online.php

case 'Jukebox':
$userinfo['action'] = 'vB Jukebox';
$userinfo['where'] = "<a href=\"vb_jukebox.php\">$vboptions[bbtitle] vB Jukebox</a>";
break;

case 'vb_jukebox.php':
$userinfo['activity'] = 'vB Jukebox';
break;


But it still shows unknown location
(I added it below your LinkMe code)

Any idea?

And without my "fix" you don?t have a location in the navbar ;)

Greetings

StarBuG

Your code is correct. So you either have a comma wrong or you placed it into the wrong section.

And thanks for the navbar hint. I will build this into the next version.

Cheers,

StarBuG 05-09-2004 07:23 PM

Quote:

Originally Posted by Pseudomizer
Your code is correct. So you either have a comma wrong or you placed it into the wrong section.

And thanks for the navbar hint. I will build this into the next version.

Cheers,

I put it exactly below your code infact I copied your code and just replaced the needed parts.

here:

case 'LinkMe':
$userinfo['action'] = 'LinkMe';
$userinfo['where'] = "<a href=\"LinkMe.php\">$vboptions[bbtitle] LinkMe</a>";
break;
case 'Jukebox':
$userinfo['action'] = 'vB Jukebox';
$userinfo['where'] = "<a href=\"vb_jukebox.php\">$vboptions[bbtitle] vB Jukebox</a>";
break;
default:
if ($permissions['wolpermissions'] & CANWHOSONLINEBAD)


AND:

case 'LinkMe.php':
$userinfo['activity'] = 'LinkMe';
break;
case 'vb_jukebox.php':
$userinfo['activity'] = 'vB Jukebox';
break;
default:
$userinfo['activity'] = 'unknown';
}

Can it be that there is something that needs to be in the file vb_jukebox.php too to work?

Star

Pseudomizer 05-09-2004 07:29 PM

Quote:

Originally Posted by StarBuG
I put it exactly below your code infact I copied your code and just replaced the needed parts.

here:

case 'LinkMe':
$userinfo['action'] = 'LinkMe';
$userinfo['where'] = "<a href=\"LinkMe.php\">$vboptions[bbtitle] LinkMe</a>";
break;
case 'Jukebox':
$userinfo['action'] = 'vB Jukebox';
$userinfo['where'] = "<a href=\"vb_jukebox.php\">$vboptions[bbtitle] vB Jukebox</a>";
break;
default:
if ($permissions['wolpermissions'] & CANWHOSONLINEBAD)


AND:

case 'LinkMe.php':
$userinfo['activity'] = 'LinkMe';
break;
case 'vb_jukebox.php':
$userinfo['activity'] = 'vB Jukebox';
break;
default:
$userinfo['activity'] = 'unknown';
}

Can it be that there is something that needs to be in the file vb_jukebox.php too to work?

Star

It can't be THIS_SCRIPT because i had this wrong and it worked for me. :surprised:

So it is either the globaltemplate or the include of the global.php. I did nothing else.

Cheers,

StarBuG 05-09-2004 07:39 PM

YES

I solved it!!! hehe

The second entry

$userinfo['activity'] = 'Jukebox';

determens the location-
The first entry handles the display in the useronline view
where

case 'Jukebox':

is definded by "activity" ;)

Just in case anyone wants to know

Thx for the quick help and for this nice hack

If you want to have some suggestions to improve your hack:

It would be good to be able to define folders outside of the forum cause I store my banners outside the forum and like it is now I have to update both folders when I add banners

Greetings

StarBuG


All times are GMT. The time now is 07:59 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.01376 seconds
  • Memory Usage 1,813KB
  • 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
  • (2)bbcode_code_printable
  • (15)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)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