apidoc
[ class tree: apidoc ] [ index: apidoc ] [ all elements ]

Class: HTML_Template_Flexy_Translator

Source Location: /HTML_Template_Flexy-1.3.13/HTML/Template/Flexy/Translator.php

Class Overview




Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 40]


[ Top ]


Class Variables

$appURL =

[line 67]

app URL (copied from above)
  • Access: public

Type:   string


[ Top ]

$languages = array()

[line 68]


Type:   mixed


[ Top ]

$options = array(
        'baseLang'          => 'en',            // the language the templates are in.
        'targetLangs'       => array('fr'),// the language the templates are being translated to.
'templateDir'=>'',// these are read from global config if not set.
'compileDir'=>'','url_rewrite'=>'',// for image rewriting.. -- needs better thinking through!
'appURL'=>'',// url to translation too : eg. /admin/translator.php
'Translation2'=>array('driver'=>'dataobjectsimple','options'=>'translations'),)

[line 48]

Options for Translator tool.
  • Access: public

Type:   array


[ Top ]

$status = array()

[line 82]

Array of objects with name, md5's, has it been set, the translation etc.
  • Access: public

Type:   array


[ Top ]

$translate =  ''

[line 89]

The current language
  • Access: public

Type:   array


[ Top ]

$translationMap = array()

[line 305]


Type:   mixed


[ Top ]

$translations = array()

[line 304]


Type:   mixed


[ Top ]

$words = array()

[line 75]

Array of templates and the words found in each one.
  • Access: public

Type:   array


[ Top ]



Method Detail

HTML_Template_Flexy_Translator (Constructor)   [line 103]

none HTML_Template_Flexy_Translator( [array $options = array()])

constructor

Just set options (no checking done)

  • Access: public

Parameters:

array   $options   —  see options array in file.

[ Top ]

clearTemplateCache   [line 434]

none clearTemplateCache( [string $lang = 'en'], [string $d = ''])

delete all the compiled templates in a specified language
  • Access: public

Parameters:

string   $lang   —  language
string   $d   —  subdirectory of templateDir or empty

[ Top ]

compileAll   [line 376]

none compileAll( [string $d = ''])

compile all the templates in a specified folder.
  • Access: public

Parameters:

string   $d   —  subdirectory of templateDir or empty

[ Top ]

getSuggestions   [line 330]

void getSuggestions( $string, $lang)


Parameters:

   $string   — 
   $lang   — 

[ Top ]

getTranslation   [line 354]

void getTranslation( $page, $word, $lang)


Parameters:

   $page   — 
   $word   — 
   $lang   — 

[ Top ]

loadTranslations   [line 315]

void loadTranslations( [string $lang = false])

LoadTranslations - load all the translations from the database into $this->translations[{lang}][{id}] = $translation;
  • Access: public

Parameters:

string   $lang   —  Language

[ Top ]

outputDefaultTemplate   [line 469]

none outputDefaultTemplate( )

output the default template with the editing facilities.
  • Access: public

[ Top ]

process   [line 145]

none process( $get, $post, array $_GET;, array $_POST;)

process the input
  • Access: public

Parameters:

array   $_GET;   —  (translate = en)
array   $_POST;   —  (translate = en, en[{md5}] = translation)
   $get   — 
   $post   — 

[ Top ]


Documentation generated on Mon, 11 Mar 2019 16:00:04 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.