vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   news hack for vb220_221en--by Arrow (https://vborg.vbsupport.ru/showthread.php?t=32549)

epic 11-20-2001 10:00 PM

newsfaderHACK--ZTSKY,2001.04.23
This zip file has three files:newsfader.php??fader.js??newshackforvb2
******abolve is originally author's info ******

******rehacked to 220??221 by arrow??2001,11,18******
================================================== ===
My zip file has three files:newsfader.php??fader.js??newshackforvb220_22 1en.txt??this file??
First excuse my worse english,let's start to hack

1??Open file: admin/index.php

Find??
makenavoption("Add","announcement.php?action=add", "|");
makenavoption("Modify","announcement.php?action=mo dify");
makenavselect("Announcements");
// ***

Below it add code??
makenavoption("Add","newsfade.php?action=add","|") ;
makenavoption("Modify","newsfade.php?action=modify ");
makenavselect("News");
// ***

2??Open file: index.php

Find??

$permissions=getpermissions();
if (!$permissions['canview']) {
show_nopermission();
}

Below it add code??

// newsfade hack start
$newsfadebits = "";
$newsfades=$DB_site->query("SELECT title,pagetext FROM announcement WHERE enddate>='$datenow' AND forumid=0 ORDER BY startdate DESC");
while ($newsfade=$DB_site->fetch_array($newsfades)) {
$newsfadebits.="\"".addslashes($newsfade[pagetext])."\",\"$newsfade[title]\",\n";
}
$newsfadebits = substr($newsfadebits,0,-2);
// newsfade hack end

3??Modify template??forumhome

Find??

<meta name="description" content="$bbtitle is a discussion forum powered by vBulletin. To visit the forum, go to $bburl/ . To find out about vBulletin, go to http://www.vbulletin.com/ .">
<title>$bbtitle - powered by vBulletin</title>
$headinclude

Below it add code??

<SCRIPT LANGUAGE='JavaScript1.2' TYPE='text/javascript'>
prefix="";
arNews = [
$newsfadebits
]
</SCRIPT>
<SCRIPT LANGUAGE='JavaScript1.2' SRC='fader.js' TYPE='text/javascript'></script>
</head>
<body>

??note: add before $header??

Conitue find??

$unregwelcomemessage
</table>
<!-- /text -->

<br>

<!-- main -->

Below it add code??

<table bgcolor="#0A293E" cellpadding="4" cellspacing="1" width="100%" border="0">
<TR bgcolor="#1D6AA0" id=cat><TD colspan=6>
<normalfont color="#000000">Forum news</normalfont></td>
</tr>
<tr><td colspan=6 bgcolor="#f7f7f7" height=30 valign="top" align="center">
<div id="elFader" style="position:relative;visibility:hidden;width:5 00"><div align="center">Forum news</div></div>
</td></tr>
<table bgcolor="#0A293E" cellpadding="4" cellspacing="1" width="100%" border="0">
<tr align="center">

4??upload newsfader.php to your forum's admin directory;
upload fader.js to your forum's root directory;
upload fade.gif to your forum's root directory,it's ok now!
Can u enjoy it?

snyx 11-21-2001 12:05 AM

ummm, sorry but can someone explain the £º and other odd charatcers Im not understanding? (maybe its a canadian thing)

Syphin 11-21-2001 01:14 AM

There just from a diffrent language... Just take all the odd ones out, and it will be regular... :p

-Syphin

LawnDawg 11-21-2001 01:57 AM

I see ZTSKY, so I'm assuming those characters are Chinese chars.

squawell 11-21-2001 02:46 AM

first thankz for this hack but i have one problem
PHP Code:

  $newsfadebits "\"welcome new member<b>$newusername</b>\",\"\",\n"

i use this code but it did not show up the username

what's wrong??

epic 11-21-2001 03:37 AM

1. use "ultra edit32" open hack's txt file.
2. this hack can use in vbb220 or vbb221 because this code:

$newsfades=$DB_site->query("SELECT title,pagetext FROM announcement WHERE enddate>='$datenow' AND forumid=0 ORDER BY startdate DESC");

3. this code

$newsfadebits = "\"welcome new member<b>$newusername</b>\",\"\",\n";


I have no time to test.Because i have not use this code. :rolleyes:

FWC 11-21-2001 03:46 AM

Quote:

Originally posted by squawell
first thankz for this hack but i have one problem
PHP Code:

  $newsfadebits "\"welcome new member<b>$newusername</b>\",\"\",\n"

i use this code but it did not show up the username

what's wrong??

You have to move the code for index.php further down the page. $newusername hasn't been determined yet if you put it where the instructions say. I put it right after:
PHP Code:

// get newest member
$getnewestusers=$DB_site->query_first("SELECT userid,username FROM user WHERE userid=$numbersmembers[max]");
$newusername=$getnewestusers['username'];
$newuserid=$getnewestusers['userid']; 

on my test board and it works that way.

squawell 11-21-2001 05:07 AM

Quote:

Originally posted by FWC
You have to move the code for index.php further down the page. $newusername hasn't been determined yet if you put it where the instructions say. I put it right after:
PHP Code:

// get newest member
$getnewestusers=$DB_site->query_first("SELECT userid,username FROM user WHERE userid=$numbersmembers[max]");
$newusername=$getnewestusers['username'];
$newuserid=$getnewestusers['userid']; 

on my test board and it works that way.

hey man ur right!!

i moved this code and it work~~

thankz~~u give me a big help again!!:D

FWC 11-21-2001 05:41 AM

Quote:

Originally posted by squawell

hey man ur right!!

i moved this code and it work~~

thankz~~u give me a big help again!!:D

I installed it on our live site. Glad to help again. :)

Lesane 11-21-2001 10:34 AM

Any change that this gonna work on 2.0.3?

fixer 11-21-2001 10:38 AM

would it work with vb2.0.3?

TheComputerGuy 11-21-2001 12:18 PM

this is just the update for VB 2.20 1

Psychdrone 11-23-2001 01:19 AM

wait i am pitigul...... I installed it but now how do i put in news?

SilverArrow 11-23-2001 01:36 AM

Just a side note:

I did NOT write this hack, and have nothing to do with it.

Lesane 11-23-2001 06:18 AM

Quote:

Originally posted by Psychdrone
wait i am pitigul...... I installed it but now how do i put in news?
In your admin on the left frame under Announcements, you see News
Add | Modify

TheComputerGuy 11-23-2001 10:21 AM

I would love to see what this does first...

snyx 11-25-2001 05:40 PM

installed, and it works
but im having some problems?

I want ALL text to be BOLD and all links to be BOLD+UNDERLINED but when I input this into the fader, it doesnt work

help? here is my fader file:

FWC 11-25-2001 07:01 PM

Quote:

Originally posted by snyx
I want ALL text to be BOLD and all links to be BOLD+UNDERLINED but when I input this into the fader, it doesnt work
Are you using bold HTML tags when you enter the news? I do and it works fine.

Psychdrone 11-25-2001 09:40 PM

Hey what do i add, to make it say, welcome to our nbewest member ______

FWC 11-25-2001 10:50 PM

Quote:

Originally posted by Psychdrone
Hey what do i add, to make it say, welcome to our nbewest member ______
Make the first line of the index.php part of the hack look like this:
PHP Code:

 $newsfadebits "\"Welcome to our newest member <b>$newusername</b>\",\"\",\n"


snyx 11-26-2001 02:23 AM

arg, im so lazy tho...

Psychdrone 11-26-2001 07:35 PM

hmmmmm thanks for your help, but it only says welcome to or newest member, by the way i am using 2.2.1 so maybe its a different code?

THANKSA!!

FWC 11-26-2001 08:31 PM

Quote:

Originally posted by Psychdrone
hmmmmm thanks for your help, but it only says welcome to or newest member, by the way i am using 2.2.1 so maybe its a different code?

THANKSA!!

Read the first page of this thread. I explain how to fix that there. You have to move the hack further down in index.php so the $newusername value is determined before this hack. It's always a good idea to read the whole thread before installing a hack. I even read the 15 page ones. :)

JTMON 11-27-2001 01:01 AM

Quote:

Originally posted by FWC
Read the first page of this thread. I explain how to fix that there. You have to move the hack further down in index.php so the $newusername value is determined before this hack. It's always a good idea to read the whole thread before installing a hack. I even read the 15 page ones. :)
TRUE TRUE:D

And that vBStats thread was insane! but worth every bit!

JTMON 11-27-2001 01:39 AM

Quote:

Originally posted by Psychdrone
hmmmmm thanks for your help, but it only says welcome to or newest member, by the way i am using 2.2.1 so maybe its a different code?

THANKSA!!

I'm having the same problem, I put the code where you said but it doesn't cycle for some reason?

JTMON 11-27-2001 01:43 AM

I just reread the instructions. Didn't realize I had to move the entire hack below that line. DOH :D

FWC 11-27-2001 01:46 AM

Quote:

Originally posted by JTMON
I just reread the instructions. Didn't realize I had to move the entire hack below that line. DOH :D
It works now. That's what counts. :)

JTMON 11-27-2001 01:48 AM

Well acutally no it's not now either :(

I made the changes, but it only shows the new member, then it cycles away and nothing comes up. I added a test news messge too:(

JTMON 11-27-2001 01:50 AM

:rolleyes:

again I misspoke. It cycles to my test message but because I hyperlinked it, it's the same color as the bacground:D

How do I change the fader background color? and font color on fader itself?

Also, it cylces to my test message and stops. shouldn't it keep going in a circle back to newest member?

FWC 11-27-2001 02:00 AM

Quote:

Originally posted by JTMON
:rolleyes:

again I misspoke. It cycles to my test message but because I hyperlinked it, it's the same color as the bacground:D

How do I change the fader background color? and font color on fader itself?

Also, it cylces to my test message and stops. shouldn't it keep going in a circle back to newest member?

The fader background color and font color are at the top of the fader.js file. You can also change the color of the cell around the fader in the forumhome template addition. I am not sure why you wouldn't continuously cycle unless you changed the number of cycles in the fader.js file. I think it defaults to 100.

JTMON 11-27-2001 02:14 AM

Can I use the vbulletin variables like {tableheadcolor} in the .js file?

THANK YOU:D:D:D:D:D:D

JTMON 11-27-2001 02:23 AM

No you can't I find out;)

All is working! Thanks FWC!! and Arrow for this hack!!

xug 11-27-2001 01:31 PM

Thank You, Thank You, Thank You !!

It's working great !

Lesane 12-05-2001 10:51 AM

One question, i added:

PHP Code:

$newsfadebits "\"Welcome to our newest member <b>$newusername</b>\",\"\",\n"

After this:

PHP Code:

// get newest member
$getnewestusers=$DB_site->query_first("SELECT userid,username FROM user WHERE userid=$numbersmembers[max]");
$newusername=$getnewestusers['username'];
$newuserid=$getnewestusers['userid']; 

And it works fine, it says: Welcome to our newest member username....

but it dont scrolls to the next news item, it only says welcome to our newest member :(

Does anyone know how 2 fix this?

JTMON 12-05-2001 06:33 PM

I had the same problem, the solution is on page 1 of this hack, you need to move ALL the code below a certain point.

JTMON 12-05-2001 10:27 PM

Anyone know how I can have birthdays auto-show in there for 1 day?

Psychdrone 12-05-2001 10:36 PM

that would be sweet, the birth day thingy!

Lesane 12-06-2001 07:46 AM

Quote:

Originally posted by JTMON
I had the same problem, the solution is on page 1 of this hack, you need to move ALL the code below a certain point.
Thanks, first it didnt worked but then i replaced this rule:

PHP Code:

$newsfadebits ""

with:

PHP Code:

$newsfadebits "\"Welcome to our newest member <b>$newusername</b>\",\"\",\n"

And it works perfect now :)

Lesane 12-06-2001 08:35 AM

Quote:

Originally posted by JTMON
Anyone know how I can have birthdays auto-show in there for 1 day?
Maybe:

PHP Code:

$newsfadebits "\"Happy Birthday to <b>$birthdays</b>\",\"\",\n"

???

Lesane 12-06-2001 02:32 PM

Or maybe this hack helps:
https://vborg.vbsupport.ru/showthrea...threadid=20344


All times are GMT. The time now is 06: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.01672 seconds
  • Memory Usage 1,843KB
  • 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
  • (10)bbcode_php_printable
  • (13)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)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