![]() |
[HTL] Addon: Auto-populate NavBar popup menu [for Erwin's Flash Player]
Addon: Auto-populate NavBar popup menu [for Erwin's Flash Player]
Version: 1.2 vB-version: 3.0.0 Release Candidate 3 Developer: Natch Install difficulty: Easy-as File edits: 2 Template edits: 2 Description of the Hack: This takes all your Flash Games you have uploaded into the /forums/games/ folder, and parses them into an array, then creates a vB3 (so cool) drop-down menu, and populates that menu with nicely-labelled links to every one of your games (provided they have the extension .swf. HACK INSTALLATION DETAILS: Files modified for this Hack: global.php includes/functions.php Templates modified for this Hack: navbar NOTE: In attachment are both HTL and text instructions. Pop the HTL file and the XML file into your htlfiles folder (remember to ensure the htl file is uploaded as BINARY) and run it thru the HTL, or read the text file and DIY :) Enjoy! and props to Erwin for his great work ... UPDATE: 1.2 Upgraded to HTL format. UPDATE: 1.1 Added a script to format visible link names more neatly. RELEASE: 1.0 Initial vB.org release. |
I have a question. Is there any way that you can use the swfs array to populate another array, where you can tell it to use titles, etc via switch?
So like it goes through the swfs array and as it populates, it runs it through a switch to determine a Formal title for the file, like blaster.sfw becomes Blaster Is that possible? I think it would make the hack more credible (although that's a great job done already!), and it would make the forums using it more professional. I don't have enough knowledge in PHP to even begin thinking about how to do it... so this is just a suggestion/request I guess. :) Thanks again! I'm going to install this weekend regardless. Chris |
Quote:
Done @ 5:05PM +10GMT 23-01-2004 :) |
Nice Job Natcher!!! :D
|
it's compatible RC3 ?
|
Quote:
|
When I enter the following into global.php on RC3 my forum comes up as a blank white page. When I remove this line, the forum loads fine. It still doesn't fetch the games though:
PHP Code:
|
Quote:
a) Edit the path to your forums in the line above this one and b) make all the other alterations as well ? The only reason this line will actually do anything is if you also have made the additions to the includes/functions.php file, and added the approriate changes to the navbar template. |
Quote:
This hack-addon is RC3 compatible. |
Updated to HTL version: text file instructions still retained for DIY-ers.
|
When I tried to load in the HTL version, I got a database error...
I went to "Install Hack" via the HTL, and chose the "Auto-Populate Navbar popup menu [for Erwin's Flash Player]" from the list. Then I hit the confirm button, and it wasn't happy. Any ideas? Code:
Database error in vBulletin 3.0.0 Release Candidate 3: |
Well the error is referring to the hacklog table, saying
Code:
mysql error: Unknown column 'changetype' in 'field list' Q: had you removed all alterations from your manual install ? [and can you edit your post to use {php} or {code} tags - that would make sure this entry full of hack-modifications is displayed properly ...] |
[QUOTE=CdaKnight]When I tried to load in the HTL version, I got a database error...
I went to "Install Hack" via the HTL, and chose the "Auto-Populate Navbar popup menu [for Erwin's Flash Player]" from the list. Then I hit the confirm button, and it wasn't happy. Any ideas? Quote:
|
Quote:
the query says to insert these file/template modifications to hackid=1, but that one is reserved for the HTL itself... *so confused* *so scared that he had a major f*ckup in his script* :'((( |
I don't have that column, although now I'm guessing I should... I used the installer... Is it possible to just drop 'hack' and 'hacklog' and run the installer to add them again (I'm assuming I wouldn't need the phrases, etc. again [including the file changes])
Kura, if you'd like to access my admincp, or need a copy of the files, please let me know what you need and I'll PM it to you. And I could have sworn I installed the upgrade... and I'll check again and make sure I did it correctly. I'm normally not this incompetent with this stuff... Oh, and PS: I never had a manual install. I chose to wait due to time constraints, and was very happy when you release the HTL version, saving me time. |
Quote:
|
Quote:
1) make sure you have the Hack_Tracking_Log.htl file in your htlfiles/ directory; 2) go to Manage Hacks -> Edit Hack Details for the Hack Tracking Log entry; 3) disable all steps for the Install Routine except Run Queries; 4) Save. Now go to Run Install Sequence (it's in the drop-down Controls menu) for the Hack Tracking Log; 5) Choose to run a Real Install, and click Proceed (or Continue?). You will now only encounter the Run Queries step. It will perform that step, which will clear out your hack and hacklog tables entirely!. 6) You will now have an empty HTL installation, which is baaaaad. :) So, we fix! Go to install hack, and choose the Hack Tracking Log that is listed there. Choose Import to Db only ! Hit proceed. 7) The HTL will now be imported to your system, but it will not appear as properly installed, but as Imported-only. To fix that, run this query on your database (manually): UPDATE hack SET atstep=-1 WHERE hackid=1; add a table prefix in front of "hack" if you have one. Then your HTL installation should be fully operational again, and have the column changetype. If not, your .htl file is corrupted somehow, outdated-beyond-all-outdatedness. Natch: pretty much, yeah... |
I think I've done something horribly wrong. So I just dropped the hack log tables, redownloaded everything, and reinstalled. Works like a bute.
However, I have two problems with this actual hack now. :\ 1) The phrase you specify in your instructions is different that the one inserted into the phrase database. 2) The Javascript menu isn't coming up. I get the little arrow, however the title "Flash", and the titles of all the games come on top of my welcome DIV. |
Quote:
If this is the case, then that would explain why your menu title ain't workin' ;) What is the phrase title that is being inserted ? |
It was just "flash_title" instead of "flash_addon_title". I was simply alerting you so that it can be remedied. I changed the phrase to match the one inserted by the install in the template, however the menu itself is not being created via the javascript.
Lemme post a screen of what's happening. |
Quote:
You are missing the all-important opening <div id=$vbphrase[flash_addon_title]> bit - probably lost when you removed the conditional in one of the navbar inserts. And the other problem is it seems you have left the conditional in place for one fo the navbar alterations, but removed it in the other - check that out as well. Check that you have inserted all but the llines containing <if statements - if you want me too look @ your admincp, PM me. Re: the phrase being mis-inserted, I'll look into that ASAP :) thanks for the heads-up. |
And one more question, and then I'll leave you alone.
For your function that retrieves the flash array, and then displays it, how would I use that on a seperate page? (I'm interesting in having a flash page on my website, which links to flash.php for the forums) |
Quote:
For more detail, PM me an IM id - MSN or ICQ and we can chat further about your needs ... :ninja: |
OK - new version of attachment uploaded with different filename so you can get the latest file regardless of your cache offering you older files.
|
Quote:
|
Quote:
I'd love your feedback to see if I did it right :) |
Quote:
|
I think the only problem that he has concerns his phrase xml file. I just noticed a difference between the one in the template, and the one actually put into the phrase. Easy to fix, I would presume.
|
Quote:
Cheers for being my test-bunny :) |
hey natch... is there any chance this can be modified to work wit the v3 arcade? i dont know anything about making hacks but it seems quite similar...?
cheers in advance! |
Quote:
I'll take a look @ it soonest :) and will post in that thread when I have it workin' |
cheers bud !!!
/me looks forward to pressing the install button |
Quote:
|
Quote:
|
Thanks for helping me with my prob Natch. I noticed something though. I'm not sure if it's just on my end or if it's a bug. It will autopopulate when on the forum or anywhere else. But will not autopopulate while on the screen where you are playing the flash game.
|
Take a closer look: the popup menu's actually render behind some screen elements: this flash player being one of them...
If it's a problem, try moving the first navbar template mod to teh extreme left or right of the navbar (e.g., make it the first or last TD in the TR ...) If u need a hand with this, lemme know. |
Yea, ur right. Thanks :)
|
I have asked the writer of the Arcade if he's OK with my porting this across for his hack, and have not received a Yea or Nay for this - if anyone is interested in this I am happy to talk them thru how to modify this for the Arcade, but I will not be publicly releasing it with the OK from John.
EDIT: OK'ed and released! :) |
how come there is no install button?
|
Quote:
|
All times are GMT. The time now is 04:44 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|