• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

[Znote AAC] Flags for characterview and highscores

Raggaer

Godly Member
Joined
Jul 25, 2012
Messages
1,557
Solutions
8
Reaction score
957
Location
Spain
Hello this will add flags to your website like in gesior!
Tested in TFS_02
- Images -

Untitled-2.jpg

Untitled-4.jpg

Untitled-6.jpg

- Install -

Download attachment
Drag highscores.php , characterprofile.php, register.php to your Znote folder
Then go to engine\function\ and drag users.php there
Add flag folder to your Znote folder
Execute this query

Code:
ALTER TABLE `accounts`
ADD `flag` VARCHAR( 20 ) NOT NULL;

Code:
ALTER TABLE `znote_accounts`
ADD `flag` VARCHAR( 20 ) NOT NULL;

And we are done! ( old accounts wont have flag )

View attachment flaggy.rar
 
I don't recommend altering the original TFS tables, thats why I made the znote_ structure.

You can fetch info from znote account table by simply calling this function:
PHP:
<?php
// Fetch flag from znote account table
$account_data = user_znote_account_data($account_id, 'flag');

// Test echo where I echo flag id:
echo $account_data['flag'];
?>
 
Hello otlanders!
I have a question about Znote.

How I put the Flag-Country in Onlinelist.php?
Thanks a lot.
 
I don't recommend altering the original TFS tables, thats why I made the znote_ structure.

You can fetch info from znote account table by simply calling this function:
PHP:
<?php
// Fetch flag from znote account table
$account_data = user_znote_account_data($account_id, 'flag');

// Test echo where I echo flag id:
echo $account_data['flag'];
?>

Where would i put that? :p sorry im new
 
When i open My account it appears some errors:

Notice: Undefined index: name in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: name in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: level in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: vocation in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: town_id in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: lastlogin in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: online in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Notice: Undefined index: name in C:\xampp\htdocs\znoteaac\myaccount.php on line 144

Warning: mysql_result() [function.mysql-result]: Unable to jump to row 0 on MySQL result index 32 in C:\xampp\htdocs\znoteaac\engine\function\users.php on line 1040

Warning: mysql_result() [function.mysql-result]: Unable to jump to row 0 on MySQL result index 33 in C:\xampp\htdocs\znoteaac\engine\function\users.php on line 1046

Notice: Undefined index: name in C:\xampp\htdocs\znoteaac\myaccount.php on line 146
 
This is a updated version wroted by me but the idea and base was formed by @Raggaer

What I did was using Znote inbuild functions for cleaner code + By an idea of @Znote of using the znote structure instead of altering the tfs original tables.

What you need to add only to the database to make it all work is

Code:
ALTER TABLE `znote_accounts`
ADD `flag` VARCHAR( 20 ) NOT NULL;

Download : http://www43.zippyshare.com/v/tpSWRg5w/file.html
Github changed made : https://github.com/Tandloze/ZnoteAAC/commit/ec5f2add006956a18bf7bf1b81eea69e5514681b

Sorry for another msg but those commits where not showing all of it but this does
https://github.com/Tandloze/ZnoteAAC/commit/9891c9859e6f9a2e89b43af7d13448cac5d07e85

dont work!
 
Well this works for - 1.5 znote aac -
And you must know what version of znote you downloaded cause if u downloaded from a post in otland ( 1.4) or you downloaded the github.com version (1.5)
 
Well this works for - 1.5 znote aac -
And you must know what version of znote you downloaded cause if u downloaded from a post in otland ( 1.4) or you downloaded the github.com version (1.5)

No one error here, but dont show the flag
eMnMEbi.png
 
Back
Top