friendly table names

G

Guy

Guest
Hi,

Is there anywhere to add a friendly table name option for each table? i.e. my table is called ga_news - i want the section to be called 'News'

Similar to the way you can set friendly names for form fields to make it easier for the user to administer.

Cheers

Guy

 
A

anton

Guest
Hi,
i have had the same problem and
this is my quick and dirty solution:

in the dadabik database there is a table named: dadabik_table_list;
add a field to this table named table_alias (or whatever)
now you can register a user friendly name for all of your tables
in the database.
I have included the function to retrieve the alias name (see below)
Hope this helps you

//retrieve the alias name for a given table
//input: $table = the formal dadabik table name
//output the user friendly table name
///////////////////////////////////////////////////////////////////////////////
function fetch_dbalias($table)
{
$Sql ='SELECT * FROM dadabik_table_list WHERE name_table = "'.$table.'"';
$results = mysql_query($Sql) or die ('<p>Error during set alias query execution.');
$row_object = mysql_fetch_object($results);
return $row_object->table_alias;

}
 
J

Jmessick

Guest
Check in the internal Table manager. I think you can change the names To "friendly Names".

You shouldnt hae to make changes to your script or code if I'm not mistaken
 
B

bglkk

Guest
I only see "friendly field names" in internal table manager. Am I missing something?

Anton, looks good. If I may inquire, where did you put your new function?
 
A

anton

Guest
Hi,

I have included a seperate php file with some functions
of my one

but a good place could be
\include\business_logic.php
 
E

Eugenio

Guest
This feature is not available at the moment, if you think it could be useful post it on the feature suggest forum.



(Latest version of DaDaBIK when this message was posted: 2.2.1)
 
Top