Previous Thread
Next Thread
Print Thread
Rate Thread
Joined: Jan 2001
Posts: 184
Member
Member
Offline
Joined: Jan 2001
Posts: 184
This is for UBB hackers only.

If this has been posted already, my apolgies, but I got it to work and some of you may find this useful for future hacking. I've included editorial comment at the end as I have some thoughts on this.

First the procedure, how to create manage/hack a custom wordlet file into the CP, where xxxx is the name you made up:

1) always name it "vars_wordlet_xxxx.cgi"
2) in cp.cgi add in a new require statement so the file is included, i.e.

Code
code:

3) hack cp_common.pl template as follows:

After line 133 (in the wordlets section, and userStatus is administrator) add in the HTML like this:

Code
code:

4) hack cp_wordlets.cgi in UBB cgi-bin dir:

After line 26 (before any elsif conditions that follow) add:

Code
code:

Then find:

Code
code:

Directly BELOW that add:

Code
code:

Done.

I used the above procedure and got it to work great. Now for a couple of caveats or suggestions:

* I advise using the format of vars_wordlets.cgi to create your new wordlet file (use the name => q~data~, syntax for each field)
* The method I used makes sure the wordlet can only be modified by the administrator. Knowing this, be careful how you insert the HTML into cp_common.pl template.


Now for an editorial comment:

InfoPop coulda used better subroutines with less redundancy, make everthing a variable and allow definition of wordlet files in cp.cgi which defines their names and authorized users (i.e. admin only). Thus, we'd only hafta hack some HTML in the template and a few lines in cp.cgi. This was poorly designed in that sense. My concern is to hack the CP takes alot of effort on the end user and are documentation will be longer. This is not the end of the world, but it sure could be better planned out to reduce typing and redundancy of sub routines.

Okay, I got that outta my system. If any questions or comments, go for it. All in all, it wasn't hard to do and works like a charm on my UBB6 gold. I'll be porting my login.cgi hack to the CP for both wordlet and feature configuration.

-jim

[edited to add tab into CP display]

[ March 22, 2001: Message edited by: hate98 ]

Sponsored Links
Joined: Jul 2000
Posts: 1,349
Ell Offline
Member
Member
Offline
Joined: Jul 2000
Posts: 1,349
Good work hate. As UBB hackers, we need more standards in doing things.

*Two thumbs up*


Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
isaac
isaac
California
Posts: 1,157
Joined: July 2001
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
WebGuy 2
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)