Hey.. I need someone hwo can help me making my sql table..
I have no php skills. I have payed for a php program that shoud make dictation for people that have some problems reading danish.. with sound and text..
When I'm making the dictation with PHP I'm getting an error like this.: Query failed (SELECT word FROM repository): Table 'test_dig_dk.re pository' doesn't exist
the first one of the php, that I soud use for makeing the text is..
[PHP]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Nyt diktat</title>
<link href="style.css " rel="stylesheet " type="text/css" />
</head>
<body>
<h1 align="center"> Nyt diktat</h1>
<form class="standard " action="select_ audio.php?mode= create" method="post">
<p>
<label for="title">Tit el:</label>
<input type="text" name="title" id="title"<? if(isset($_POST['title'])) echo " value=\"".$_POS T['title']."\"";?> />
</p>
<p>
<label for="content">I ndhold:</label><br />
<textarea name="content" id="content" cols="100" rows="40"><? if(isset($_POST['title'])) echo implode("",file ("text/".$_POST['title'].".txt"));?> </textarea>
</p>
<p>
<input type="submit" value="Væ lg lyd" />
</p>
</form>
</body>
</html>
[/PHP]
And the 2'nd one is were I soud upload the au.file sound..
[PHP]<?
require("databa se.inc.php");
{connectDatabas e();}
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Væ lg lyd til <?=$_POST['title']?></title>
<link href="style.css " rel="stylesheet " type="text/css" />
</head>
<body>
<? if(file_exists( "text/".$_POST['title'].".txt")) {
?>
<h1>Væl g lyd</h1>
<h3 style="color:#C C3333">Pas på! Der findes allerede et diktat med denne titel.<br />
Hvis du er ved at lave et nyt diktat, burde du gå <a href="javascrip t:history.back( )">tilbage</a> og vælge en anden titel.
Gør du ikke det, bliver diktatet med titelen "<?=$_P OST['title']?>" erstattet med dette diktat her!</h3>
<?
}
?>
<form enctype="multip art/form-data" action="save_di ct.php" method="post">
<input type="hidden" name="MAX_FILE_ SIZE" value="500000" />
<table border="0">
<?
$query = "SELECT word FROM repository";
$result = mysql_query($qu ery) or die("Query failed ($query): " . mysql_error());
$word_start=0;
$word_stop=0;
$open=false;
$words=array();
$content=$_POST['content'];
for($i=0;$i<str len($content);$ i++) {
if(substr($cont ent,$i,1)=="<" && !$open) {
$word_start=$i+ 1;
$open=true;
}
elseif(substr($ content,$i,1)== ">" && $open) {
$word_stop=$i;
$word=substr($c ontent,$word_st art,$word_stop-$word_start);
if(!in_array($w ord,$repository )) {
$words[]=$word;
?>
<tr>
<td><?=$word? ></td>
<td><input type="file" name="<?=$word? >" /></td>
</tr>
<?
}
$open=false;
}
}
?>
</table>
<input type="hidden" name="words" value="<? echo implode(";",$wo rds); ?>" />
<input type="hidden" name="content" value="<?=$_POS T['content']?>" />
<input type="hidden" name="title" value="<?=$_POS T['title']?>" />
<input type="submit" value="Upload & save" />
</form>
</body>
</html>
[/PHP]
I hope that you can see what the table is. and that you will help me creating it....
Thanks..
2 6662 pbmods 5,821
Recognized Expert Expert
Heya, Kilo.
Changed thread title to better describe the problem (did you know that threads whose titles do not follow the Posting Guidelines actually get FEWER responses?).
In this function:
Are you mysql_select_db ()ing the correct database?
I have the database inc.php were the database is connectet. all of the php make a requst to database.inc.ph p..
And still tray to create a dicttation whithen this link of create.dict.php ..and i can't see what the missing table is..
Database.inc.ph p
[php]
<?
function connectDatabase () {
$connect=mysql_ connect("localh ost","test_dig_ dk","password!! !");
$select=mysql_s elect_db("test_ dig_dk",$connec t);
if(!$connect || !$select)
{
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Fehler beim Verbinden mit der Datenbank</title>
</head>
<body>
<p>Es ist beim Verbinden mit der Datenbank ein Fehler aufgetreten!</p>
</body>
</html>
<?
exit();
}
}
?>[/php]
Sign in to post your reply or Sign up for a free account.
Similar topics |
by: g |
last post by:
Is there a method where by I could check for a certain table or query
exist in my access database file before I made query to it??
|
by: dummie_q |
last post by:
Hey,
I am having some confusion about how to formulate this particular
query.
I have 2 tables. Table A has 4 columns say a1,a2,a3,a4 with the
columns a1,a2,a4 forming the primary key. Table B again has 3 columns
with b1,b2,b3,b4 and like before, b1,b2 and b4 form the primary key.
All columns are of the same datatype in both tables. Now I want to get
rows from table A which are not present in table B. Whats the best way
of doing this?
|
by: Bob Bedford |
last post by:
We have no access to a mysql NG on my provider's server, so we ask here:
We have a long query (long in text) with a UNION between 2 select.
We have been informed that some times the query doesn't return any result.
We have tried on our server and we always get a result. BUT, trying on the
hosting server, many times the query doesn't return any result and doesn't
get any error.
Any idea ? does Union have any problem ? how to check if...
|
by: Steve M |
last post by:
A few users today received the message "The trust relationship between this
workstation and the primary domain failed" on their web browser while using
an ASP.NET web app. The problem went away but has anyone seen this before
on a error page? I think it occured when users were reporting general slow
web performance. I've seen it while users try to log into an NT domain from
their desktops but not while using a web browser. Users can log...
|
by: Galka |
last post by:
Hello
Why do you think a create table query doesn't create table from the
following code?
Set myQuery = myDB.QueryDefs("qryCON absent adults previous day log")
myQuery.Execute
If I execute the query myself, it creates the table perfectly well.
When executed from code, an error is 3061: too few parameters. Expected
| |
by: sansann |
last post by:
Hello there!
i need help on loading data from my Access database query table name combine into my MSFlexgrid select by batchno category. when i runn below coding the error said "Selected collating sequence not supported by operating system"
Private Sub Command1_Click()
Dim search As String
Dim index As Integer
search = keybatch.Text
|
by: 4.spam |
last post by:
Hello, all.
DB2 v8.2.7, DB2 v9.1.3, Windows XP.
When I choose this menu item (this menu appears when I right click a
database) in db2cc nothing is happening on both versions of db2cc.
When I try the same running v8 db2cctrc.bat (db2cc with trace), I see
java stack trace with null pointer exception.
I will try tomorrow v9 db2cctrc.bat.
Explain tables exist.
|
by: sa6113 |
last post by:
I am using this code to connect to a windows machine using paramiko, I have
installed sshd on the machine and it works properly:
sock.connect((hostname, port))
t = paramiko.Transport(sock)
event = threading.Event()
t.start_client(event)
event.wait()
if not t.is_active():
print 'SSH negotiation failed.'
|
by: moltendorf |
last post by:
I copied the files from my "test" database on my old server (MySQL was not running) to my new server ("./mysql/data/test" folder), and after starting the server, SHOW TABLES; shows all of the tables that are supposed to be there, but running a SELECT * FROM `configuration`; (for example) returns "test.configuration does not exist).
I've tried the following repair statement since I'm not too familiar with backing up and restoring data.
...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |