Mercurial > hg > extraction-interface
annotate interface/add_missing_books_to_sections.php @ 14:ac77748bb813
- Load regex files based on current topic. Only show the regex in this topic.
To do that, it needs to lookup a table called 'topic_regex_relation' which has the relation of topic and regex filename in filesystem.
- Extractapp UI with some layout modification: button, popup window, responsive (by bootstrap now). It was just for quick prototyping.
| author | Zoe Hong <zhong@mpiwg-berlin.mpg.de> |
|---|---|
| date | Thu, 19 Feb 2015 11:07:27 +0100 |
| parents | 883ad980a43b |
| children |
| rev | line source |
|---|---|
|
2
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
1 <?php |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
2 include_once('Lib_mb_utf8.php'); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
3 include_once('config.php'); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
4 include_once('edit_section_db.php'); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
5 set_time_limit(0); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
6 ini_set('memory_limit', '-1'); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
7 |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
8 $link_mysql = mysql_connect($mysql_server, $mysql_user, $mysql_password); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
9 mysql_query("SET NAMES utf8"); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
10 |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
11 if (!$link_mysql) { |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
12 die('Could not connect: ' . mysql_error()); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
13 } |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
14 |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
15 $db_selected = mysql_select_db($mysql_database, $link_mysql); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
16 if (!$db_selected) { |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
17 die ('Can\'t use foo : ' . mysql_error()); |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
18 } |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
19 |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
20 |
|
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
21 |
|
4
883ad980a43b
add dynasty column to table books
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
2
diff
changeset
|
22 add_missing_books_to_sections(); |
|
883ad980a43b
add dynasty column to table books
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
2
diff
changeset
|
23 |
|
2
da5309d54083
add missing books to sections as dummy entries for further modification.
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
diff
changeset
|
24 |
|
4
883ad980a43b
add dynasty column to table books
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
2
diff
changeset
|
25 |
|
883ad980a43b
add dynasty column to table books
Zoe Hong <zhong@mpiwg-berlin.mpg.de>
parents:
2
diff
changeset
|
26 |
