Create or edit single word.
More...
Create or edit single word.
Call: edit_word.php?.... ... op=Save ... do insert new ... op=Change ... do update ... fromAnn=recno ... calling from impr. annotation editing ... tid=[textid]&ord=[textpos]&wid= ... new word
... tid=[textid]&ord=[textpos]&wid=[wordid] ... edit word
- Since
- 1.0.3
- Author
- LWT Project lwt-p.nosp@m.roje.nosp@m.ct@ho.nosp@m.tmai.nosp@m.l.com
◆ change_term_display()
| change_term_display |
( |
|
$wid, |
|
|
|
$translation, |
|
|
|
$hex |
|
) |
| |
Echoes a JavaScript element, that will edit terms diplay
◆ edit_term()
| edit_term |
( |
|
$translation | ) |
|
Edit an existing term.
- Parameters
-
| string | $translation | New translation for this term |
- Returns
- array{0: string, 1: string} Word id, and then an insertion message
◆ edit_word_do_form()
| edit_word_do_form |
( |
|
$fromAnn | ) |
|
Sets the translation of a term.
Sets the romanization of a term.
◆ insert_new_word()
| insert_new_word |
( |
|
$textlc, |
|
|
|
$translation |
|
) |
| |
Insert a new word to the database
- Parameters
-
| string | $textlc | The word to insert, in lowercase |
| string | $translation | Translation of this term |
- Returns
- array{0: int, 1: string} Word id, and then an insertion message
◆ lowercase_term_not_equal()
| lowercase_term_not_equal |
( |
|
$textlc | ) |
|
Use this function if the lowercase version of the word does not correspond. It will echo an error message.
- Parameters
-
| string | $textlc | The lowercase version of the word we want. |
◆ else
| if (isset( $_REQUEST[ 'op'])) else |
Initial value:{
$translation = $translation_raw